Skip to content

Commit

Permalink
Move favicon logic to parent route
Browse files Browse the repository at this point in the history
  • Loading branch information
futa-ikeda authored and bp-cos committed Nov 30, 2023
1 parent a675d4c commit aef7c09
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions app/preprints/index/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,17 @@ export default class Preprints extends Route {
return null;
}
}

afterModel(model: PreprintProviderModel) {
if (model && model.assets && model.assets.favicon) {
const headTags = [{
type: 'link',
attrs: {
rel: 'icon',
href: model.assets.favicon,
},
}];
this.set('headTags', headTags);
}
}
}

0 comments on commit aef7c09

Please sign in to comment.