r20160118

This commit is contained in:
flash 2016-01-18 21:21:08 +01:00
parent c334721bd1
commit 25f032b470
7 changed files with 10 additions and 15 deletions

View file

@ -358,11 +358,6 @@ class User
return [0, 'USER_NOT_EXIST']; return [0, 'USER_NOT_EXIST'];
} }
// Check if the user has this user a friend
if (!$this->isFriends($uid)) {
return [0, 'ALREADY_REMOVED'];
}
// Remove friend // Remove friend
Database::delete('friends', [ Database::delete('friends', [
'user_id' => [$this->id, '='], 'user_id' => [$this->id, '='],

View file

@ -465,7 +465,7 @@ class Users
// Send the message // Send the message
Utils::sendMail( Utils::sendMail(
[ [
$user->email() => $user->username, $user->email => $user->username,
], ],
Config::get('sitename') . ' Activation Mail', Config::get('sitename') . ' Activation Mail',
$message $message

View file

@ -1122,14 +1122,15 @@ a.default:active {
} }
#notifications > div > .notification-close { #notifications > div > .notification-close {
height: 40px; height: 40px !important;
width: 40px; width: 40px !important;
margin: 0; margin: 0;
padding: 0; padding: 0 !important;
border: 0; border: 0;
margin-right: 4px; margin-right: 4px;
visibility: visible; visibility: visible;
flex-shrink: 0; flex-shrink: 0;
font-size: 2em !important;
} }
#notifications > div > .notification-close > div { #notifications > div > .notification-close > div {

View file

@ -1222,7 +1222,7 @@ if (Users::checkLogin()) {
'menu' => true, 'menu' => true,
], ],
], ],
], ]/*,
'messages' => [ 'messages' => [
'title' => 'Messages', 'title' => 'Messages',
'modes' => [ 'modes' => [
@ -1259,7 +1259,7 @@ if (Users::checkLogin()) {
'menu' => false, 'menu' => false,
], ],
], ],
], ]*/,
'notifications' => [ 'notifications' => [
'title' => 'Notifications', 'title' => 'Notifications',
'modes' => [ 'modes' => [

View file

@ -8,7 +8,7 @@
namespace Sakura; namespace Sakura;
// Define Sakura version // Define Sakura version
define('SAKURA_VERSION', '20160117'); define('SAKURA_VERSION', '20160118');
define('SAKURA_VLABEL', 'Amethyst'); define('SAKURA_VLABEL', 'Amethyst');
define('SAKURA_COLOUR', '#9966CC'); define('SAKURA_COLOUR', '#9966CC');

View file

@ -32,7 +32,6 @@
All active users in the past {{ sakura.onlineTimeout / 60 }} minute{% if sakura.onlineTimeout != 60 %}s{% endif %} All active users in the past {{ sakura.onlineTimeout / 60 }} minute{% if sakura.onlineTimeout != 60 %}s{% endif %}
<table class="panelTable"> <table class="panelTable">
{% for amount,onlineUser in stats.onlineUsers %} {% for amount,onlineUser in stats.onlineUsers %}
{% if amount != (stats.onlineUsers|length - 1) %}, {% endif %}
<tr><td style="text-align: left;"><a href="{{ urls.format('USER_PROFILE', [onlineUser.id]) }}" style="font-weight: bold; color: {{ onlineUser.colour }};" class="default">{{ onlineUser.username }}</a></td><td title="{{ onlineUser.lastOnline|date(sakura.dateFormat) }}" style="text-align: right;">{{ onlineUser.elapsed.lastOnline }}</td></tr> <tr><td style="text-align: left;"><a href="{{ urls.format('USER_PROFILE', [onlineUser.id]) }}" style="font-weight: bold; color: {{ onlineUser.colour }};" class="default">{{ onlineUser.username }}</a></td><td title="{{ onlineUser.lastOnline|date(sakura.dateFormat) }}" style="text-align: right;">{{ onlineUser.elapsed.lastOnline }}</td></tr>
{% endfor %} {% endfor %}
</table> </table>

View file

@ -109,7 +109,7 @@
} }
{% endif %} {% endif %}
{% if php.self == '/authenticate.php' and not sakura.lockAuth %} {% if php.self == '/authenticate.php' and not (sakura.lockAuth or session.checkLogin) %}
// AJAX Form Submission // AJAX Form Submission
var forms = { var forms = {
@ -171,7 +171,7 @@
<!-- User menu, displayed on right side of the bar. --> <!-- User menu, displayed on right side of the bar. -->
{% if session.checkLogin %} {% if session.checkLogin %}
<a class="menu-item avatar" href="{{ urls.format('USER_PROFILE', [user.id]) }}" title="Logged in as {{ user.username }}" style="background-image: url('{{ urls.format('IMAGE_AVATAR', [user.id]) }}'); width: auto; color: {{ user.colour }}; border-color: {{ user.colour }}; font-weight: 700;"></a> <a class="menu-item avatar" href="{{ urls.format('USER_PROFILE', [user.id]) }}" title="Logged in as {{ user.username }}" style="background-image: url('{{ urls.format('IMAGE_AVATAR', [user.id]) }}'); width: auto; color: {{ user.colour }}; border-color: {{ user.colour }}; font-weight: 700;"></a>
<a class="menu-item fa-envelope" href="{{ urls.format('SETTING_CAT', ['messages']) }}" title="Messages"></a> {#<a class="menu-item fa-envelope" href="{{ urls.format('SETTING_CAT', ['messages']) }}" title="Messages"></a>#}
{% if user.permission(constant('Sakura\\Perms\\Manage::USE_MANAGE'), constant('Sakura\\Perms::MANAGE')) %} {% if user.permission(constant('Sakura\\Perms\\Manage::USE_MANAGE'), constant('Sakura\\Perms::MANAGE')) %}
<a class="menu-item fa-gavel" href="{{ urls.format('MANAGE_INDEX') }}" title="Manage"></a> <a class="menu-item fa-gavel" href="{{ urls.format('MANAGE_INDEX') }}" title="Manage"></a>
{% endif %} {% endif %}