We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6f4c386 commit 7660dd8Copy full SHA for 7660dd8
1 file changed
src/app/shared/utils/safe-url-pipe.ts
@@ -10,6 +10,6 @@ import { DomSanitizer } from '@angular/platform-browser';
10
export class SafeUrlPipe implements PipeTransform {
11
constructor(private domSanitizer: DomSanitizer) { }
12
transform(url) {
13
- return this.domSanitizer.bypassSecurityTrustResourceUrl(url);
+ return url == null ? null : this.domSanitizer.bypassSecurityTrustResourceUrl(url);
14
}
15
0 commit comments