mirror of
https://gitlab.com/ruany/litebans-php.git
synced 2025-08-21 12:12:24 +00:00
Fix new expiry method issues
This commit is contained in:
parent
bfccfee536
commit
663221c76a
13
inc/page.php
13
inc/page.php
@ -267,8 +267,8 @@ class Page {
|
|||||||
} else {
|
} else {
|
||||||
$until = $this->millis_to_date($row['until']);
|
$until = $this->millis_to_date($row['until']);
|
||||||
}
|
}
|
||||||
|
$expired = $this->is_expired($row);
|
||||||
if ($this->active($row) === false) {
|
if ($this->active($row) === false) {
|
||||||
$until .= ' ';
|
|
||||||
|
|
||||||
$done = false;
|
$done = false;
|
||||||
|
|
||||||
@ -284,18 +284,21 @@ class Page {
|
|||||||
$name = $this->clean($row['removed_by_name']);
|
$name = $this->clean($row['removed_by_name']);
|
||||||
}
|
}
|
||||||
if ($name !== null) {
|
if ($name !== null) {
|
||||||
$until .= str_replace('{name}', $name, $this->expired_by[$this->type]);
|
$until .= ' ' . str_replace('{name}', $name, $this->expired_by[$this->type]);
|
||||||
$done = true;
|
$done = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ($this->is_expired($row)) {
|
if ($expired) {
|
||||||
$until .= $this->lang->page_expire;
|
|
||||||
$done = true;
|
$done = true;
|
||||||
}
|
}
|
||||||
if ($done === false) {
|
if ($done === false) {
|
||||||
$until .= $this->expired[$this->type];
|
$until .= ' ' . $this->expired[$this->type];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if ($expired) {
|
||||||
|
$until .= ' ';
|
||||||
|
$until .= $this->lang->page_expire;
|
||||||
|
}
|
||||||
return $until;
|
return $until;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user