question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Fetch My Campaigns: Uncaught (in promise) TypeError: campaigns is undefined

See original GitHub issue

When trying to fetch my campaigns I get the following output in the developer console:

Uncaught (in promise) TypeError: campaigns is undefined [Settings.js:387]
[Detected 1 package: ddb-importer]
    activateListeners Settings.js:387
    jQuery 9
        dispatch
        handle
        add
        Ee
        each
        each
        Ee
        on
        n
    activateListeners Settings.js:382
    _render foundry.js:3090
    _render foundry.js:3764
    render foundry.js:3021
    _onClickSubmenu foundry.js:55705
    jQuery 2
        dispatch
        handle

I am using Firefox 100.0.2 as a browser and my Foundry VTT instance (Version 9, Build 269) is running on a CentOS 7 machine. D&D Beyond importer is on version 2.9.48 and my cobalt cookie was freshly reset.

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:14 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
miri64commented, Jun 7, 2022

If you know what the campaign ID (it’s a number, you can find it in the URL of your campaign on DDB) you can manually set it using:

game.settings.set(“ddb-importer”, “campaign-id”, “ID_HERE”)`

That worked! Thanks.

As a work around you could also try setting these details using my proxy and then switching back to your local one once complete

Already tried that earlier, same result. But I’m happy with the console-based workaround.

1reaction
miri64commented, Jun 6, 2022

I think this is a core foundry problem at this point - you may need to remove the file from the disk, and also from the json manifest for your world.

That worked btw!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Uncaught (in promise) TypeError: response is undefined using ...
It looks like the fetch is failing, triggering the catch , which converts rejection into fulfillment with undefined . You'll need to look...
Read more >
Issues · MrPrimate/ddb-importer - GitHub
Fetch My Campaigns : Uncaught (in promise) TypeError: campaigns is undefined bug Something isn't working. #240 opened on Jun 5 by miri64.
Read more >
Troubleshooting Analytics.js | Segment Documentation
If you get an undefined error, Analytics.js is not loading successfully: Returning analytics object error. Solution: Follow the Analytics.js ...
Read more >
Common Issues | Google Ads scripts (Legacy)
My script runs, but doesn't do anything ; Version 2 (doesn't work). function main() { // Call to getAllCampaigns is missing, so this...
Read more >
Resolving the JavaScript Promise Error "TypeError: Cannot ...
After all, you get this error when calling the then() method on a Promise . And the TypeError indicates you are calling then()...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found