ZP-1090 Use PING_HIGHER_BOUND_LIFETIME when available for the default ping...

ZP-1090 Use PING_HIGHER_BOUND_LIFETIME when available for the default ping lifetime. Released under the Affero GNU General Public License (AGPL) version 3.
parent b8be1f7a
......@@ -441,11 +441,16 @@ class SyncCollections implements Iterator {
* previousily set or saved in a collection
*
* @access public
* @return int returns 600 as default if nothing set or not available
* @return int returns PING_HIGHER_BOUND_LIFETIME as default if nothing set or not available.
* If PING_HIGHER_BOUND_LIFETIME is not set, returns 600.
*/
public function GetLifetime() {
if (!isset( $this->refLifetime) || $this->refLifetime === false)
if (!isset($this->refLifetime) || $this->refLifetime === false) {
if (PING_HIGHER_BOUND_LIFETIME !== false) {
return PING_HIGHER_BOUND_LIFETIME;
}
return 600;
}
return $this->refLifetime;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment