From 5079082d0d94b9e91e8bb75f877d93e54e77b647 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Mon, 27 Jun 2022 13:51:46 +0200 Subject: Fix boolean data attributes in homepage --- client/src/app/shared/shared-main/video/video.service.ts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'client/src/app') diff --git a/client/src/app/shared/shared-main/video/video.service.ts b/client/src/app/shared/shared-main/video/video.service.ts index 142367506..9efa1a24e 100644 --- a/client/src/app/shared/shared-main/video/video.service.ts +++ b/client/src/app/shared/shared-main/video/video.service.ts @@ -423,14 +423,14 @@ export class VideoService { if (skipCount) newParams = newParams.set('skipCount', skipCount + '') - if (isLocal) newParams = newParams.set('isLocal', isLocal) - if (include) newParams = newParams.set('include', include) - if (isLive) newParams = newParams.set('isLive', isLive) - if (nsfw) newParams = newParams.set('nsfw', nsfw) - if (nsfwPolicy) newParams = newParams.set('nsfw', this.nsfwPolicyToParam(nsfwPolicy)) - if (languageOneOf) newParams = this.restService.addArrayParams(newParams, 'languageOneOf', languageOneOf) - if (categoryOneOf) newParams = this.restService.addArrayParams(newParams, 'categoryOneOf', categoryOneOf) - if (privacyOneOf) newParams = this.restService.addArrayParams(newParams, 'privacyOneOf', privacyOneOf) + if (isLocal !== undefined) newParams = newParams.set('isLocal', isLocal) + if (include !== undefined) newParams = newParams.set('include', include) + if (isLive !== undefined) newParams = newParams.set('isLive', isLive) + if (nsfw !== undefined) newParams = newParams.set('nsfw', nsfw) + if (nsfwPolicy !== undefined) newParams = newParams.set('nsfw', this.nsfwPolicyToParam(nsfwPolicy)) + if (languageOneOf !== undefined) newParams = this.restService.addArrayParams(newParams, 'languageOneOf', languageOneOf) + if (categoryOneOf !== undefined) newParams = this.restService.addArrayParams(newParams, 'categoryOneOf', categoryOneOf) + if (privacyOneOf !== undefined) newParams = this.restService.addArrayParams(newParams, 'privacyOneOf', privacyOneOf) return newParams } -- cgit v1.2.3