From 54f430572c1bf7ab9461620603fb4d2637a598c1 Mon Sep 17 00:00:00 2001 From: flashwave Date: Mon, 27 Apr 2015 17:04:27 +0000 Subject: [PATCH] 20150427.6 --- _sakura/changelog.json | 16 +++++++++++++++- _sakura/components/Main.php | 11 +++-------- _sakura/sakura.php | 2 +- _sakura/templates/yuuno/main/profile.tpl | 2 +- 4 files changed, 20 insertions(+), 11 deletions(-) diff --git a/_sakura/changelog.json b/_sakura/changelog.json index 78f4b51..bcfeeda 100644 --- a/_sakura/changelog.json +++ b/_sakura/changelog.json @@ -13,7 +13,8 @@ "20150427.2", "20150427.3", "20150427.4", - "20150427.5" + "20150427.5", + "20150427.6" ] @@ -758,6 +759,19 @@ "change": "Redid avatar serving script." } + ], + + "20150427.6": [ + + { + "type": "FIX", + "change": "Hide abyss'd users." + }, + { + "type": "REM", + "change": "Remove origin check on CloudFlare country header." + } + ] } diff --git a/_sakura/components/Main.php b/_sakura/components/Main.php index f92d5da..0e70d56 100644 --- a/_sakura/components/Main.php +++ b/_sakura/components/Main.php @@ -407,14 +407,9 @@ class Main { // Get country code from CloudFlare header (which just returns EU if not found) public static function getCountryCode() { - // Check if remote IP is a CloudFlare IP - if(self::checkCFIP($_SERVER['REMOTE_ADDR'])) { - - // Check if the required header is set and return it - if(isset($_SERVER['HTTP_CF_IPCOUNTRY'])) - return $_SERVER['HTTP_CF_IPCOUNTRY']; - - } + // Check if the required header is set and return it + if(isset($_SERVER['HTTP_CF_IPCOUNTRY'])) + return $_SERVER['HTTP_CF_IPCOUNTRY']; // Return EU as a fallback return 'EU'; diff --git a/_sakura/sakura.php b/_sakura/sakura.php index 695d1c9..4d36c49 100644 --- a/_sakura/sakura.php +++ b/_sakura/sakura.php @@ -8,7 +8,7 @@ namespace Sakura; // Define Sakura version -define('SAKURA_VERSION', '20150427.5'); +define('SAKURA_VERSION', '20150427.6'); define('SAKURA_VLABEL', 'Heliotrope'); define('SAKURA_VTYPE', 'Development'); define('SAKURA_COLOUR', '#DF73FF'); diff --git a/_sakura/templates/yuuno/main/profile.tpl b/_sakura/templates/yuuno/main/profile.tpl index 4b80de7..580fe14 100644 --- a/_sakura/templates/yuuno/main/profile.tpl +++ b/_sakura/templates/yuuno/main/profile.tpl @@ -1,5 +1,5 @@ {% include 'global/header.tpl' %} - {% if profile.notset or profile.user.id == 0 %} + {% if profile.notset or profile.user.id == 0 or profile.user.password_algo == 'nologin' %}

The requested user does not exist!

There are a few possible reasons for this: