Skip to content
This repository has been archived by the owner on Apr 26, 2021. It is now read-only.

Update Dt.php #4

Merged
merged 1 commit into from Oct 23, 2013
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 4 additions & 2 deletions Dt.php
Expand Up @@ -222,8 +222,10 @@ private function _fillCollections($interval, $toCurrent, &$words, &$values, &$al
$values[] = $days;

$hours = $interval->h;
$words[] = $numeral->getPlural($hours, self::$_HOUR_VARIANTS);
$values[] = $hours;
if ($hours > 0) {
$words[] = $numeral->getPlural($hours, self::$_HOUR_VARIANTS);
$values[] = $hours;
}

if ($days == 0 && $hours == 1 && $toCurrent)
$alternatives[] = 'час';
Expand Down