Title: Two errors: Custom Javascript and &#8216;Script amp-onerror`
Last modified: May 27, 2021

---

# Two errors: Custom Javascript and ‘Script amp-onerror`

 *  Resolved [mcopenhagen](https://wordpress.org/support/users/mcopenhagen/)
 * (@mcopenhagen)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/two-errors-custom-javascript-and-script-amp-onerror/)
 * Hi there,
 * I’m getting two errors on just about all of my web stories. All of these stories
   used to pass the AMP test successfully.
 * **Error 1:** Custom JavaScript is not allowed.
    **Error 2:** The mandatory text
   inside tag ‘script amp-onerror’ is missing or incorrect.
 * I’m not really sure what changed or why I’m getting these errors when I didn’t
   get them yesterday.
 * I can see other users are experiencing Error 2 so I’ll look out for the fix on
   that, but if you can provide any additional information around Error 1 that would
   be much appreciated.
 * Thanks,
    Max
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Ftwo-errors-custom-javascript-and-script-amp-onerror%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [Luckyna San](https://wordpress.org/support/users/luckynasan/)
 * (@luckynasan)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/two-errors-custom-javascript-and-script-amp-onerror/#post-14494609)
 * [@mcopenhagen](https://wordpress.org/support/users/mcopenhagen/) Hi Max, thanks
   for reaching out. We will follow up with an update on Error 2 once we have it
   as well. Regarding Error 1, we can check your Site Health information for possible
   conflicts. Could you provide your [Site Health](https://i.imgur.com/Rtkmsba.png)
   information? You can share [privately](https://docs.google.com/forms/d/e/1FAIpQLSd-AeFLOIJd4NLYz7EDUa9vMfzZIoT5Bn1leV3dL2CM_B1C6Q/viewform)
   if you prefer.
 *  Thread Starter [mcopenhagen](https://wordpress.org/support/users/mcopenhagen/)
 * (@mcopenhagen)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/two-errors-custom-javascript-and-script-amp-onerror/#post-14494734)
 * Thank you – I just submitted the information privately.
 *  [Luckyna San](https://wordpress.org/support/users/luckynasan/)
 * (@luckynasan)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/two-errors-custom-javascript-and-script-amp-onerror/#post-14529502)
 * [@mcopenhagen](https://wordpress.org/support/users/mcopenhagen/) This issue has
   been resolved in the AMP validator and you should no longer see this `amp-onerror`
   in Search Console as well. The mini-plugin can now be safely removed accordingly
   on your site if you had installed it.
 * We will mark this topic as resolved but if you continue to experience issues,
   please submit a [new topic to the Web Stories forum](https://wordpress.org/support/plugin/web-stories/#new-post).
 * Thank you for your patience while we investigated this issue, and thank you for
   using Web Stories!

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Two errors: Custom Javascript and ‘Script amp-onerror`’ is closed to 
new replies.

 * ![](https://ps.w.org/web-stories/assets/icon.svg?rev=2386543)
 * [Web Stories](https://wordpress.org/plugins/web-stories/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/web-stories/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/web-stories/)
 * [Active Topics](https://wordpress.org/support/plugin/web-stories/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/web-stories/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/web-stories/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [Luckyna San](https://wordpress.org/support/users/luckynasan/)
 * Last activity: [4 years, 11 months ago](https://wordpress.org/support/topic/two-errors-custom-javascript-and-script-amp-onerror/#post-14529502)
 * Status: resolved