# leadflows.js overrides window.onerror

**URL:** <https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927>\
**Category:** APIs & Integrations\
**Tags:** developer-tools\
**Created:** [February 20, 2020, 4:17pm UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927 "2020-02-20T16:17:47Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![aleksandr-swoop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/aleksandr-swoop/32/92090_2.png) [@aleksandr-swoop](https://community.hubspot.com/u/aleksandr-swoop)\
**Post date:** [February 20, 2020, 4:17pm UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/1 "2020-02-20T16:17:47Z")

</div>

[https://js.hsleadflows.net/leadflows.js](https://js.hsleadflows.net/leadflows.js) overrides existing _window.onerror_ handler.

It breaks our integration with error logging library Rollbar.

leadflows.js should keep existing _window.onerror_ handler and call it on error.

Here is old similar question [https://community.hubspot.com/t5/APIs-Integrations/How-to-disable-error-logging-in-LeadIn/m-p/238152](https://community.hubspot.com/t5/APIs-Integrations/How-to-disable-error-logging-in-LeadIn/m-p/238152#M17048) But looks like it was never resolved.

I don’t know what label to choose for my question. None of them make sense to me. But label field is required.

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [February 21, 2020, 4:26am UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/2 "2020-02-21T04:26:02Z")

</div>

Hey @aleksandr-swoop,

Could you share more in details and provide screenshots on where you’re seeing that leadflow.js overrides window.onerror?

---

<div class="post-metadata">

**Author:** ![aleksandr-swoop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/aleksandr-swoop/32/92090_2.png) [@aleksandr-swoop](https://community.hubspot.com/u/aleksandr-swoop)\
**Post date:** [February 21, 2020, 3:13pm UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/3 "2020-02-21T15:13:20Z")

</div>

Hey @WendyGoh!

Here is screenshot

 ![leadflows.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/d/2/d2518f82604969782fd9b660c61533ed5dbe24a7.png)

Please let me know if you need more details.

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [February 27, 2020, 2:06am UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/4 "2020-02-27T02:06:52Z")

</div>

Hey @aleksandr-swoop,

Thanks for sharing the screenshot with me.

I’ll have to check in with our internal team on this and I’ll keep you posted here!

---

<div class="post-metadata">

**Author:** ![aleksandr-swoop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/aleksandr-swoop/32/92090_2.png) [@aleksandr-swoop](https://community.hubspot.com/u/aleksandr-swoop)\
**Post date:** [March 3, 2020, 5:33pm UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/5 "2020-03-03T17:33:28Z")

</div>

Hello @WendyGoh!

Any update on this?

Thanks,

Aleksandr

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [March 4, 2020, 1:41am UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/6 "2020-03-04T01:41:35Z")

</div>

Hey @aleksandr-swoop,

Just an update here. I’m able to confirm that currently this is how HubSpot manage errors. That said, may be your team can try exploring this option -[스포츠중계 고화질 - 해외축구중계, 무료 야구중계, 실시간 농구중계, 라이브 F1생중계, 4k 1080p화질 무료중계](https://errorception.com/docs/onerror) to work around the problem.

Let me know your thoughts!

---

<div class="post-metadata">

**Author:** ![aleksandr-swoop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/aleksandr-swoop/32/92090_2.png) [@aleksandr-swoop](https://community.hubspot.com/u/aleksandr-swoop)\
**Post date:** [March 4, 2020, 2:18am UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/7 "2020-03-04T02:18:21Z")

</div>

Hey @WendyGoh

Thank you for the article! But looks like this how HubSpot should implement it.

We use Rollbar library which is out control and it relies on window.onerror. It handles window.onerror correct way as described in article. But then HubSpot just overrides it.

We cannot delay and load HubSpot first and then Rollbar.

Thanks,

Aleksandr

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [March 4, 2020, 2:42am UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/8 "2020-03-04T02:42:35Z")

</div>

Hey @aleksandr-swoop,

Gotcha. Thank you for the clarification.

I’ll check in with my team and will definitely keep you posted here.

---

<div class="post-metadata">

**Author:** ![aleksandr-swoop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/aleksandr-swoop/32/92090_2.png) [@aleksandr-swoop](https://community.hubspot.com/u/aleksandr-swoop)\
**Post date:** [March 9, 2020, 5:14pm UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/9 "2020-03-09T17:14:26Z")

</div>

Hey @WendyGoh!

How is it going? It stuck here for couple of weeks.

Thanks,

Aleksandr

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [March 10, 2020, 1:21am UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/10 "2020-03-10T01:21:45Z")

</div>

Hey @aleksandr-swoop,

I’d like to assure you that our internal team is aware of this issue and is looking to push a fix for this. I’ll keep you posted once there’s an update.

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [March 11, 2020, 1:30am UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/11 "2020-03-11T01:30:15Z")

</div>

Hey @aleksandr-swoop,

Just an update here! Our internal team has pushed a fix for this. Could you check and see if you’re seeing seeing the issue?

---

<div class="post-metadata">

**Author:** ![aleksandr-swoop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/aleksandr-swoop/32/92090_2.png) [@aleksandr-swoop](https://community.hubspot.com/u/aleksandr-swoop)\
**Post date:** [March 24, 2020, 6:42pm UTC](https://community.hubspot.com/t/leadflows-js-overrides-window-onerror/18927/12 "2020-03-24T18:42:24Z")

</div>

Hi @WendyGoh!

Thank you! I confirm it is fixed now.

Thanks,

Aleksandr
