Minor: Format code

pull/4161/head
Angel Fernando Quiroz Campos 3 years ago
parent fec015021e
commit d582086540
  1. 3
      src/CoreBundle/Migrations/Schema/V200/Version20200821224243.php
  2. 2
      src/CoreBundle/Security/Authorization/Voter/SocialPostVoter.php

@ -62,7 +62,8 @@ final class Version20200821224243 extends AbstractMigrationChamilo
); );
$newTypeQueries[] = sprintf( $newTypeQueries[] = sprintf(
'UPDATE message SET msg_type = %d WHERE msg_type = %d', 'UPDATE message SET msg_type = %d WHERE msg_type = %d',
Message::MESSAGE_TYPE_INBOX, self::OLD_MESSAGE_STATUS_OUTBOX Message::MESSAGE_TYPE_INBOX,
self::OLD_MESSAGE_STATUS_OUTBOX
); );
$newTypeQueries[] = sprintf( $newTypeQueries[] = sprintf(

@ -76,7 +76,7 @@ class SocialPostVoter extends Voter
return false; return false;
} }
if ($post->getType() === SocialPost::TYPE_PROMOTED_MESSAGE && !$currentUser->isAdmin()) { if (SocialPost::TYPE_PROMOTED_MESSAGE === $post->getType() && !$currentUser->isAdmin()) {
return false; return false;
} }

Loading…
Cancel
Save