Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure hostspots are loaded from the right URL #24

Merged
merged 1 commit into from
Apr 22, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion addon/services/eh-hotspots.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import Service from '@ember/service';
import { tracked } from '@glimmer/tracking';
import fetch from 'fetch';
import config from 'ember-get-config';

export default class EhHotspotsService extends Service {
@tracked showHotspots = false;
Expand Down Expand Up @@ -39,7 +40,7 @@ export default class EhHotspotsService extends Service {
return;
}

const res = await fetch('/assets/eh-hotspots.json');
const res = await fetch(`${config.rootURL}assets/eh-hotspots.json`);
const data = await res.json();

this.data = data;
Expand Down