Shotgunned a fix for gallery page titles.

This commit is contained in:
WildScotsmen 2018-12-11 15:06:27 -05:00
parent 1778f02d9e
commit edfbabe08a
1 changed files with 3 additions and 18 deletions

View File

@ -41,23 +41,6 @@ const styles = theme => ({
}); });
class FlameLinkCollectionGallery extends Component { class FlameLinkCollectionGallery extends Component {
getPageTitle = galleryName => {
switch (galleryName) {
case 'martensAndKits':
document.title = 'Marten Tracker | Martens and Kits';
break;
case 'martensAtNight':
document.title = 'Marten Tracker | Martens at Night';
break;
case 'martensBeingMartens':
document.title = 'Marten Tracker | Martens Being Martens';
break;
default:
document.title = 'Marten Tracker | Galleries';
break;
}
}
constructor(props) { constructor(props) {
super(props); super(props);
@ -84,8 +67,10 @@ class FlameLinkCollectionGallery extends Component {
schemaDescription: result.title schemaDescription: result.title
})) }))
} }
}
this.getPageTitle(this.props.galleryName); componentDidMount() {
document.title = 'Marten Tracker | Galleries';
} }
getGalleryInfo(schemaDetails, schemaContent) { getGalleryInfo(schemaDetails, schemaContent) {