nativegallery-weryskok/app/Controllers/Api/Admin/Images/SetVisibility.php

18 lines
396 B
PHP
Raw Normal View History

2024-07-18 16:05:32 +03:00
<?php
namespace App\Controllers\Api\Admin\Images;
use App\Services\{Auth, Router, GenerateRandomStr, DB, Json, EXIF};
use App\Models\{User, Vote};
class SetVisibility
{
public function __construct()
{
DB::query('UPDATE photos SET moderated=:mod WHERE id=:id', array(':id'=>$_GET['id'], ':mod'=>$_GET['mod']));
header('Location: ' . $_SERVER['HTTP_REFERER']);
}
}