fix lint issues and errors

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2019-10-08 20:00:26 +02:00
parent 2749220832
commit 0820866bb8
3 changed files with 11 additions and 9 deletions

View File

@@ -152,7 +152,7 @@ import { IConfig } from '@/types/config.model';
},
})
export default class Home extends Vue {
events: Event[] = [];
events: IEvent[] = [];
locations = [];
city = { name: null };
country = { name: null };
@@ -225,8 +225,8 @@ export default class Home extends Vue {
}
get filteredFeaturedEvents() {
if (this.currentUser.isLoggedIn === false || !this.currentActor.id) return this.events;
return this.events.filter(event => event.organizerActor.id !== this.currentActor.id);
if (!this.currentUser.isLoggedIn || !this.currentActor.id) return this.events;
return this.events.filter(event => event.organizerActor && event.organizerActor.id !== this.currentActor.id);
}
geoLocalize() {