Skip to content

Commit

Permalink
fix(rgb-to-hex): fix trim function to handle falsy value(#270) (#287)
Browse files Browse the repository at this point in the history
* fix(mathers): fix hasCss if style applied but jQuery returns null (#270)

* Revert "fix(mathers): fix hasCss if style applied but jQuery returns null (#270)"

This reverts commit eda8ac3.

* fix(rgb-to-hex): fix trim function to handle falsy value(#270)
  • Loading branch information
NetanelBasal authored Mar 5, 2020
1 parent 7f559f0 commit 9269832
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion projects/spectator/src/lib/internals/rgb-to-hex.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ export function isHex(value: string): boolean {
}

export function trim(value: string): string {
return value.replace(/\s/g, '');
return (value || '').replace(/\s/g, '');
}

0 comments on commit 9269832

Please sign in to comment.