Version 4.7.8
This commit is contained in:
1 parent
7b7404e741
commit
fd22d99e69
688 files changed
+19814
-10890
No files matched your search
@@ -38,7 +38,7 @@ class _ReplyTopic extends \IPS\Content\Api\GraphQL\CommentMutator
|
||||
/*
|
||||
* Mutation arguments
|
||||
*/
|
||||
public function args()
|
||||
public function args(): array
|
||||
{
|
||||
return [
|
||||
'topicID' => TypeRegistry::nonNull( TypeRegistry::id() ),
|
||||
@@ -73,19 +73,19 @@ class _ReplyTopic extends \IPS\Content\Api\GraphQL\CommentMutator
|
||||
}
|
||||
catch ( \OutOfRangeException $e )
|
||||
{
|
||||
throw new \IPS\Api\GraphQL\SafeException( 'NO_TOPIC', '1F295/1', 403 );
|
||||
throw new \IPS\Api\GraphQL\SafeException( 'NO_TOPIC', '1F295/1_graphl', 403 );
|
||||
}
|
||||
|
||||
/* Get author */
|
||||
if ( !$topic->canComment( \IPS\Member::loggedIn() ) )
|
||||
{
|
||||
throw new \IPS\Api\GraphQL\SafeException( 'NO_PERMISSION', '2F294/A', 403 );
|
||||
throw new \IPS\Api\GraphQL\SafeException( 'NO_PERMISSION', '2F294/A_graphl', 403 );
|
||||
}
|
||||
|
||||
/* Check we have a post */
|
||||
if ( !$args['content'] )
|
||||
{
|
||||
throw new \IPS\Api\GraphQL\SafeException( 'NO_POST', '1F295/3', 403 );
|
||||
throw new \IPS\Api\GraphQL\SafeException( 'NO_POST', '1F295/3_graphl', 403 );
|
||||
}
|
||||
|
||||
$originalPost = NULL;
|
||||
|
||||
Reference in new issue
Block a user