Test Setup Failed
Pull Request — master (#522)
by Mike's
01:01
created
config.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
 }
14 14
 /** @var array $config */
15 15
 
16
-$remote_user = array_key_exists('PHP_AUTH_USER', $_SERVER) ? $_SERVER['PHP_AUTH_USER'] : '';
16
+$remote_user = array_key_exists('PHP_AUTH_USER', $_SERVER)?$_SERVER['PHP_AUTH_USER']:'';
17 17
 // Clean username, only allow a-z, A-Z, 0-9, -_ chars
18 18
 $remote_user = preg_replace('/[^a-zA-Z0-9_-]/', '', $remote_user);
19 19
 $user_config_file = 'config_local.' . $remote_user . '.php';
Please login to merge, or discard this patch.
fetch.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -26,10 +26,10 @@  discard block
 block discarded – undo
26 26
     ob_end_clean();
27 27
 }
28 28
 
29
-$expires = 60*60*24*14;
29
+$expires = 60 * 60 * 24 * 14;
30 30
 header('Pragma: public');
31 31
 header('Cache-Control: max-age=' . $expires);
32
-header('Expires: ' . gmdate('D, d M Y H:i:s', time()+$expires) . ' GMT');
32
+header('Expires: ' . gmdate('D, d M Y H:i:s', time() + $expires) . ' GMT');
33 33
 $bookId   = getURLParam('id', null);
34 34
 $type     = getURLParam('type', 'jpg');
35 35
 $idData   = getURLParam('data', null);
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
         if (isset($config['cops_thumbnail_cache_directory']) && $config['cops_thumbnail_cache_directory'] !== '') {
74 74
             $thumbnailCacheFullpath = $config['cops_thumbnail_cache_directory'];
75 75
             //if multiple databases, add a subfolder with the database ID
76
-            $thumbnailCacheFullpath .= !is_null(GetUrlParam(DB)) ? 'db-' . GetUrlParam(DB) . DIRECTORY_SEPARATOR : '';
76
+            $thumbnailCacheFullpath .= !is_null(GetUrlParam(DB))?'db-' . GetUrlParam(DB) . DIRECTORY_SEPARATOR:'';
77 77
             //when there are lots of thumbnails, it's better to save files in subfolders, so if the book's uuid is
78 78
             //"01234567-89ab-cdef-0123-456789abcdef", we will save the thumbnail in .../0/12/34567-89ab-cdef-0123-456789abcdef-...
79 79
             $thumbnailCacheFullpath .= substr($book->uuid, 0, 1) . DIRECTORY_SEPARATOR . substr($book->uuid, 1, 2) . DIRECTORY_SEPARATOR;
Please login to merge, or discard this patch.