Skip to content

Commit

Permalink
fix(datetime): allow values to be zero (#14480)
Browse files Browse the repository at this point in the history
* fix(datetime): allow values to be zero

* Using null check
  • Loading branch information
pwespi authored and manucorporat committed Aug 24, 2018
1 parent 151c58e commit e0b8e24
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/components/datetime/datetime-util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export function renderDatetime(template: string, value: DatetimeData, locale: Lo
const token = '{' + index + '}';
const text = renderTextFormat(format.f, (value as any)[format.k], value, locale);

if (!hasText && text && (value as any)[format.k]) {
if (!hasText && text && (value as any)[format.k] != null) {
hasText = true;
}

Expand Down

0 comments on commit e0b8e24

Please sign in to comment.