mirror of
https://github.com/openvk/openvk
synced 2025-01-06 16:00:00 +03:00
Compare commits
2 commits
dda86b167e
...
cf23022626
Author | SHA1 | Date | |
---|---|---|---|
|
cf23022626 | ||
|
d25c2ee183 |
4 changed files with 12 additions and 8 deletions
|
@ -24,7 +24,11 @@ class Blacklists
|
|||
|
||||
function getByAuthorAndTarget(int $author, int $target): ?BlacklistItem
|
||||
{
|
||||
return new BlacklistItem($this->blacklists->where(["author" => $author, "target" => $target])->fetch());
|
||||
$fetch = $this->blacklists->where(["author" => $author, "target" => $target])->fetch();
|
||||
if ($fetch)
|
||||
return new BlacklistItem($fetch);
|
||||
else
|
||||
return null;
|
||||
}
|
||||
|
||||
function getCount(User $user): int
|
||||
|
|
|
@ -394,7 +394,7 @@
|
|||
<div class="right_big_block">
|
||||
<div class="page_info">
|
||||
<div n:if="$isBlacklistedByThem AND $thisUser->isAdmin() AND $thisUser->getId() !== $user->getId()" class="user-alert">
|
||||
<b>{admin_privacy_warning}:</b>
|
||||
<b>{_admin_privacy_warning}:</b>
|
||||
<br/>
|
||||
{_user_blacklisted_you}
|
||||
</div>
|
||||
|
|
|
@ -2,6 +2,6 @@ CREATE TABLE `blacklists` (
|
|||
`index` BIGINT UNSIGNED NOT NULL AUTO_INCREMENT,
|
||||
`author` BIGINT UNSIGNED NOT NULL,
|
||||
`target` BIGINT UNSIGNED NOT NULL,
|
||||
`created` DATETIME NOT NULL,
|
||||
`created` BIGINT UNSIGNED NOT NULL,
|
||||
PRIMARY KEY (`index`)
|
||||
) ENGINE = InnoDB;
|
||||
|
|
Loading…
Reference in a new issue