1
0
mirror of https://github.com/vichan-devel/vichan.git synced 2024-11-12 01:50:48 +01:00

fix post event

This commit is contained in:
czaks 2014-04-29 21:18:17 +02:00
parent d57dcc5e6e
commit 46802d3f1b

View File

@ -758,7 +758,11 @@ if (isset($_POST['delete'])) {
}
$post = (object)$post;
if ($error = event('post', $post)) {
$post->files = array_map(function($a) { return (object)$a; }, $post->files);
$error = event('post', $post);
$post->files = array_map(function($a) { return (array)$a; }, $post->files);
if ($error) {
undoImage((array)$post);
error($error);
}