]> git.mxchange.org Git - friendica-addons.git/commitdiff
Move Global Functions - Part 3
authorPhilipp Holzer <admin@philipp.info>
Sat, 20 Oct 2018 16:22:13 +0000 (18:22 +0200)
committerPhilipp Holzer <admin@philipp.info>
Sat, 20 Oct 2018 16:22:13 +0000 (18:22 +0200)
- Replaced every CACHE_ definition

curweather/curweather.php
openstreetmap/openstreetmap.php

index c4cf3ab468453afbce6633e0696e901035c8e2cd..db244c7d1e5f01a52f40e3fabb096df8c3f0fe78 100644 (file)
@@ -92,7 +92,7 @@ function getWeather($loc, $units = 'metric', $lang = 'en', $appid = '', $cacheti
        ];
 
        PConfig::set(local_user(), 'curweather', 'last', $now->getTimestamp());
-       Cache::set('curweather'.md5($url), serialize($r), CACHE_HOUR);
+       Cache::set('curweather'.md5($url), serialize($r), Cache::HOUR);
 
        return $r;
 }
index 0420591eb95b414fc8288afd344c9f07fb2f8e21..a1cdd3a1bc2824357f96adb2d3e7b8728c9d1299 100644 (file)
@@ -132,7 +132,7 @@ function openstreetmap_get_coordinates($a, &$b)
                $curlResult = Network::curl($nomserver . $args);
                if ($curlResult->isSuccess()) {
                        $j = json_decode($curlResult->getBody(), true);
-                       Cache::set($cachekey, $j, CACHE_MONTH);
+                       Cache::set($cachekey, $j, Cache::MONTH);
                }
        }