mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-06 12:00:06 +02:00
This commit is contained in:
parent
27e66d89e9
commit
d50542d74b
1 changed files with 7 additions and 1 deletions
|
@ -306,8 +306,14 @@ abstract class ObjectYPT implements ObjectInterface
|
|||
//$escapedValue = $global['mysqli']->real_escape_string($this->$value);
|
||||
if (strtolower($value) == 'created') {
|
||||
//var_dump($this->created);exit;
|
||||
if (!empty($this->created) && (User::isAdmin() || isCommandLineInterface())) {
|
||||
if (
|
||||
!empty($this->created) && (
|
||||
User::isAdmin() ||
|
||||
isCommandLineInterface() ||
|
||||
(class_exists('API') && API::isAPISecretValid())
|
||||
)) {
|
||||
$this->created = preg_replace('/[^0-9: \/-]/', '', $this->created);
|
||||
_error_log("created changed in table=".static::getTableName()." id={$this->id} created={$this->created}");
|
||||
$formats .= 's';
|
||||
$values[] = $this->created;
|
||||
$fields[] = " `{$value}` = ? ";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue