Best answer

I am getting the error 'Cannot read property length of undefined' when I add more than one image in the image URL field using a SocialPilot action

  • 16 February 2021
  • 5 replies
  • 498 views

I have created a trigger for my blog and I am trying to use it with a SocialPilot action. My blogs may or may not have one or many images. I would like to send my blog to SocialPilot using either one of their provided actions: ‘Add image post to queue’ or ‘Add text post to queue’. When I use ‘Add image post to queue’ and add more than one url in the image url field I get the error ‘Cannot read property length of undefined’. If I only add one image url it works fine.

Also, I do not know how I should create my zap to handle blogs with different number of images 

icon

Best answer by GetUWired 16 February 2021, 17:47

View original

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

5 replies

Userlevel 7
Badge +12

@westcoastbc 

Just to clarify, you created a custom trigger for your blog or are using one of Zapier’s available triggers?

I am creating a custom trigger. I have tested my trigger and it looks to me that it is working correctly.

Here is a screen shot of the error:

 

Userlevel 7
Badge +12

Ahh, i see, so the error is coming from Social Pilot action, not the custom trigger?

Can you share a screenshot of your Social Pilot action set up? From the action description, it looks like SocialPilot can only accept 1 image at a time. If that is the case, you should explore the Looping by Zapier action and splitting the image urls field from your trigger into a list of urls as opposed to a text field with multiple urls. 

Here is my action setup

 

Userlevel 7
Badge +10

@westcoastbc 
Just checking in to see if you still need help with this?