diff --git a/bootstrap.php b/bootstrap.php index 64bf2a8..59c3667 100644 --- a/bootstrap.php +++ b/bootstrap.php @@ -25,6 +25,9 @@ $user->score -= $diff; $user->save(); } + if ($record && $record->review_state === ReviewState::MANUAL) { + $record->delete(); + } }); $filter->add('can_update_texture_privacy', function ($init, $texture) { // private to public diff --git a/readme.md b/readme.md index e2571b0..a324f42 100644 --- a/readme.md +++ b/readme.md @@ -1,12 +1,5 @@ # Texture Moderation -https://github.com/bs-community/blessing-skin-server/blob/dev/app/Http/Controllers/SkinlibController.php#L89 +## 如何开发 -```php -return $query->where('public', true) - ->where('state', 1); -``` - -需求文档:docs/requirement.md - -技术方案:docs/proposal.md +配置好 NodeJS 环境, `yarn global add esbuild`, 运行 `build.sh` 构建前端文件, 然后重新加载插件。 \ No newline at end of file diff --git a/src/Controllers/ModerationController.php b/src/Controllers/ModerationController.php index ab162b5..df7ff20 100644 --- a/src/Controllers/ModerationController.php +++ b/src/Controllers/ModerationController.php @@ -27,7 +27,7 @@ public static function start(Texture $texture) $record = new ModerationRecord; $record->tid = $texture->tid; $size = getimagesizefromstring($file); - if ($size[0] <= 50 || $size[1] <= 50) { + if ($size[0] <= 100 || $size[1] <= 100) { $record->review_state = ReviewState::MISS; $record->save(); return;