• Resolved sarangsss29

    (@sarangsss29)


    Upon checking search console errors for a page, I am seeing an error originating from AD Inserter plugin.

    ai-functions.min.js?ver=2.7.35:1 Uncaught

    SyntaxError:
    Identifier ‘r’ has already been declared

    Coming from wp-content/plugins/ad-inserter/js/ai-functions.min.js?ver=2.7.35

    How to fix this?

    Screenshot:

    https://snipboard.io/uINZ0Q.jpg

    The page I need help with: [log in to see the link]

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Author Spacetime

    (@spacetime)

    Hello,

    remote debugging doesn’t seem to be enabled.

    Plugin Author Spacetime

    (@spacetime)

    Do you still need help?

    Thread Starter sarangsss29

    (@sarangsss29)

    Hi @spacetime Enabled remote debugging.

    Edit: What happens in remote debugging? Do you make any changes? It is a production site and do not want to mess something up.

    • This reply was modified 3 months, 2 weeks ago by sarangsss29.
    Plugin Author Spacetime

    (@spacetime)

    Remote debugging enables us to debug plugin processing.

    Can you try to disable all caching and optimizing plugins?

    Thread Starter sarangsss29

    (@sarangsss29)

    @spacetime It’s a production site. Can’t do that.

    Plugin Author Spacetime

    (@spacetime)

    The error message doesn’t make much sense. There is no identifier r where the error is reported and that script file is not loaded as intended – it seems it is delayed.

    Therefore I believe some other code might be interferring with it.

    You can also try to set Javascript code to Inline:
    https://adinserter.pro/documentation/plugin-settings#javascript-code

    Thread Starter sarangsss29

    (@sarangsss29)

    @spacetime Thanks for the reply.

    I visited the documentation, but that is for when Ad blocking is enabled, right? I am not using ad blocking detection from Ad Inserter. It is disabled.

    So I have excluded all caching and optimization from this page, but still see the error.

    As you said, there is no identifier r where the error is reported, – so it should not be there?

    Also, the script file is not loaded as intended – is it breaking the functionality of displaying ads?

    • This reply was modified 3 months, 2 weeks ago by sarangsss29.
    Plugin Author Spacetime

    (@spacetime)

    The error message still doesn’t make sense. Completely unrelated to the source it points to.

    Now the script is not delayed anymore. It should not be delayed as it delays all client-side functions.

    Try to insert the code inline.

    Thread Starter sarangsss29

    (@sarangsss29)

    @spacetime The documentation says: default the client-side JavaScript code will be inserted?Inline? inline. How do I find out if some code is no inserted inline?

    Thread Starter sarangsss29

    (@sarangsss29)

    @spacetime Got it. I have changed the JavaScript to inline and the file is not loaded at all. Looks all good now.

    Plugin Author Spacetime

    (@spacetime)

    Great ??

Viewing 11 replies - 1 through 11 (of 11 total)
  • You must be logged in to reply to this topic.