@@ -814,7 +814,7 @@ discard block |
||
814 | 814 | 'filename' => empty($user_settings['filename']) ? '' : $user_settings['filename'], |
815 | 815 | 'custom_dir' => !empty($user_settings['attachment_type']) && $user_settings['attachment_type'] == 1, |
816 | 816 | 'id_attach' => isset($user_settings['id_attach']) ? $user_settings['id_attach'] : 0, |
817 | - 'width' => isset($user_settings['attachment_width']) > 0 ? $user_settings['attachment_width']: 0, |
|
817 | + 'width' => isset($user_settings['attachment_width']) > 0 ? $user_settings['attachment_width'] : 0, |
|
818 | 818 | 'height' => isset($user_settings['attachment_height']) > 0 ? $user_settings['attachment_height'] : 0, |
819 | 819 | ), |
820 | 820 | 'smiley_set' => isset($user_settings['smiley_set']) ? $user_settings['smiley_set'] : '', |
@@ -2469,7 +2469,7 @@ discard block |
||
2469 | 2469 | ); |
2470 | 2470 | |
2471 | 2471 | // Add the JQuery library to the list of files to load. |
2472 | - $jQueryUrls = array ('cdn' => 'https://ajax.googleapis.com/ajax/libs/jquery/'. JQUERY_VERSION . '/jquery.min.js', 'jquery_cdn' => 'https://code.jquery.com/jquery-'. JQUERY_VERSION . '.min.js', 'microsoft_cdn' => 'https://ajax.aspnetcdn.com/ajax/jQuery/jquery-'. JQUERY_VERSION . '.min.js'); |
|
2472 | + $jQueryUrls = array('cdn' => 'https://ajax.googleapis.com/ajax/libs/jquery/' . JQUERY_VERSION . '/jquery.min.js', 'jquery_cdn' => 'https://code.jquery.com/jquery-' . JQUERY_VERSION . '.min.js', 'microsoft_cdn' => 'https://ajax.aspnetcdn.com/ajax/jQuery/jquery-' . JQUERY_VERSION . '.min.js'); |
|
2473 | 2473 | |
2474 | 2474 | if (array_key_exists($modSettings['jquery_source'], $jQueryUrls)) |
2475 | 2475 | loadJavaScriptFile($jQueryUrls[$modSettings['jquery_source']], array('external' => true, 'seed' => false), 'smf_jquery'); |
@@ -2710,8 +2710,7 @@ discard block |
||
2710 | 2710 | $context['css_files_order'] = array(); |
2711 | 2711 | |
2712 | 2712 | $params['seed'] = (!array_key_exists('seed', $params) || (array_key_exists('seed', $params) && $params['seed'] === true)) ? |
2713 | - (array_key_exists('browser_cache', $context) ? $context['browser_cache'] : '') : |
|
2714 | - (is_string($params['seed']) ? '?' . ltrim($params['seed'], '?') : ''); |
|
2713 | + (array_key_exists('browser_cache', $context) ? $context['browser_cache'] : '') : (is_string($params['seed']) ? '?' . ltrim($params['seed'], '?') : ''); |
|
2715 | 2714 | $params['force_current'] = isset($params['force_current']) ? $params['force_current'] : false; |
2716 | 2715 | $themeRef = !empty($params['default_theme']) ? 'default_theme' : 'theme'; |
2717 | 2716 | $params['minimize'] = isset($params['minimize']) ? $params['minimize'] : true; |
@@ -2826,8 +2825,7 @@ discard block |
||
2826 | 2825 | global $settings, $context, $modSettings; |
2827 | 2826 | |
2828 | 2827 | $params['seed'] = (!array_key_exists('seed', $params) || (array_key_exists('seed', $params) && $params['seed'] === true)) ? |
2829 | - (array_key_exists('browser_cache', $context) ? $context['browser_cache'] : '') : |
|
2830 | - (is_string($params['seed']) ? '?' . ltrim($params['seed'], '?') : ''); |
|
2828 | + (array_key_exists('browser_cache', $context) ? $context['browser_cache'] : '') : (is_string($params['seed']) ? '?' . ltrim($params['seed'], '?') : ''); |
|
2831 | 2829 | $params['force_current'] = isset($params['force_current']) ? $params['force_current'] : false; |
2832 | 2830 | $themeRef = !empty($params['default_theme']) ? 'default_theme' : 'theme'; |
2833 | 2831 | $params['async'] = isset($params['async']) ? $params['async'] : false; |
@@ -2932,7 +2930,7 @@ discard block |
||
2932 | 2930 | $elements[] = JavaScriptEscape($element); |
2933 | 2931 | } |
2934 | 2932 | |
2935 | - $value = '[' . implode(', ',$elements) . ']'; |
|
2933 | + $value = '[' . implode(', ', $elements) . ']'; |
|
2936 | 2934 | } |
2937 | 2935 | } |
2938 | 2936 | |
@@ -3613,8 +3611,7 @@ discard block |
||
3613 | 3611 | |
3614 | 3612 | // What accelerator we are going to try. |
3615 | 3613 | $cache_class_name = !empty($cache_accelerator) ? $cache_accelerator : CacheApi::APIS_DEFAULT; |
3616 | - $fully_qualified_class_name = !empty($overrideCache) ? $overrideCache : |
|
3617 | - CacheApi::APIS_NAMESPACE . $cache_class_name; |
|
3614 | + $fully_qualified_class_name = !empty($overrideCache) ? $overrideCache : CacheApi::APIS_NAMESPACE . $cache_class_name; |
|
3618 | 3615 | |
3619 | 3616 | // Do some basic tests. |
3620 | 3617 | if (class_exists($fully_qualified_class_name)) |
@@ -3918,7 +3915,7 @@ discard block |
||
3918 | 3915 | $auth_secret = hash_file('sha256', $boarddir . '/Settings.php'); |
3919 | 3916 | |
3920 | 3917 | // Set the last error to now, but only every 15 minutes. Don't need to flood the logs. |
3921 | - if (empty($db_last_error) || ($db_last_error + 60*15) <= time()) |
|
3918 | + if (empty($db_last_error) || ($db_last_error + 60 * 15) <= time()) |
|
3922 | 3919 | { |
3923 | 3920 | updateDbLastError(time()); |
3924 | 3921 | loadLanguage('Errors'); |