Update Auth.php

Fixed an issue when we try to install baikal on Synology NAS.
touch() function is not supported on this hardaware.

use file_put_contents () does not interfere with the logic of the code and provides better compatibility as touch() also has other problems on Windows OS

http://synology.com

http://blog.idleman.fr/installez-votre-synchronisateurs-de-contacts-chez-vous-avec-baikal/
Former-commit-id: 23646af674
This commit is contained in:
torzak 2013-11-05 12:36:06 +01:00
parent 6dd6896f7a
commit ec38c5c3fb

View file

@ -59,7 +59,7 @@ class Auth {
if((time() - $iTime) < 3600) {
# file has been created/updated less than an hour ago; update it's mtime
if(is_writable($sEnableFile)) {
@touch($sEnableFile);
@file_put_contents($sEnableFile, '');
}
$bLocked = FALSE;
} else {
@ -125,4 +125,4 @@ class Auth {
public static function lockInstall() {
@unlink(PROJECT_PATH_SPECIFIC . "ENABLE_INSTALL");
}
}
}