mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-07-21 09:03:38 +02:00
bug 1328: implements check_pwg_token for comment deletion on picture.php
git-svn-id: http://piwigo.org/svn/branches/2.0@4509 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -149,7 +149,8 @@ SELECT id,author,date,image_id,content
|
||||
$url_self,
|
||||
array(
|
||||
'action'=>'delete_comment',
|
||||
'comment_to_delete'=>$row['id']
|
||||
'comment_to_delete'=>$row['id'],
|
||||
'pwg_token'=>get_pwg_token(),
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
@@ -309,6 +309,8 @@ UPDATE '.CATEGORIES_TABLE.'
|
||||
}
|
||||
case 'delete_comment' :
|
||||
{
|
||||
check_pwg_token();
|
||||
|
||||
if (isset($_GET['comment_to_delete'])
|
||||
and is_numeric($_GET['comment_to_delete'])
|
||||
and is_admin() and !is_adviser() )
|
||||
|
||||
Reference in New Issue
Block a user