X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fdatetime.php;h=cb27799798b0c3c5a269eae3e8df8b882bd45125;hb=755f6e8cc1ceb5fab0c0f63deb3ca7048d1ea48d;hp=f525f1234d4b8094cf029aa1e488126c402185c7;hpb=0dfa57948f152a90a4d8093419a2ea5ced07349c;p=friendica.git diff --git a/include/datetime.php b/include/datetime.php index f525f1234d..cb27799798 100644 --- a/include/datetime.php +++ b/include/datetime.php @@ -6,6 +6,7 @@ use Friendica\Core\Config; use Friendica\Core\PConfig; +use Friendica\Database\DBM; /** * @brief Two-level sort for timezones. @@ -280,10 +281,7 @@ function timesel($format, $h, $m, $id = 'timepicker') { function datetimesel($format, $min, $max, $default, $label, $id = 'datetimepicker', $pickdate = true, $picktime = true, $minfrom = '', $maxfrom = '', $required = false) { // First day of the week (0 = Sunday) - $firstDay = PConfig::get(local_user(), 'system', 'first_day_of_week'); - if ($firstDay === false) { - $firstDay=0; - } + $firstDay = PConfig::get(local_user(), 'system', 'first_day_of_week', 0); $lang = substr(get_browser_language(), 0, 2); @@ -592,7 +590,7 @@ function update_contact_birthdays() { // In-network birthdays are handled within local_delivery $r = q("SELECT * FROM `contact` WHERE `bd` != '' AND `bd` > '0001-01-01' AND SUBSTRING(`bd`, 1, 4) != `bdyear` "); - if (dbm::is_result($r)) { + if (DBM::is_result($r)) { foreach ($r as $rr) { logger('update_contact_birthday: ' . $rr['bd']); @@ -614,7 +612,7 @@ function update_contact_birthdays() { dbesc(datetime_convert('UTC','UTC', $nextbd)), dbesc('birthday')); - if (dbm::is_result($s)) { + if (DBM::is_result($s)) { continue; }