diff options
-rw-r--r-- | lib/Command/Fediverse.php | 4 | ||||
-rw-r--r-- | lib/Command/MigrateAlpha3.php | 4 | ||||
-rw-r--r-- | lib/Command/NoteCreate.php | 12 | ||||
-rw-r--r-- | lib/Command/QueueStatus.php | 2 | ||||
-rw-r--r-- | lib/Db/ActorsRequest.php | 6 | ||||
-rw-r--r-- | lib/Db/ActorsRequestBuilder.php | 2 | ||||
-rw-r--r-- | lib/Db/CacheActorsRequest.php | 4 | ||||
-rw-r--r-- | lib/Db/ClientRequest.php | 2 | ||||
-rw-r--r-- | lib/Db/CoreRequestBuilder.php | 4 | ||||
-rw-r--r-- | lib/Db/RequestQueueRequest.php | 10 | ||||
-rw-r--r-- | lib/Db/SocialCrossQueryBuilder.php | 4 | ||||
-rw-r--r-- | lib/Db/StreamActionsRequest.php | 6 | ||||
-rw-r--r-- | lib/Db/StreamQueueRequest.php | 4 | ||||
-rw-r--r-- | lib/Db/StreamRequest.php | 38 | ||||
-rw-r--r-- | lib/Db/StreamRequestBuilder.php | 8 | ||||
-rw-r--r-- | lib/Migration/Version1000Date20221118000001.php | 8 | ||||
-rw-r--r-- | lib/Tools/Traits/TNCLogger.php | 24 |
17 files changed, 71 insertions, 71 deletions
diff --git a/lib/Command/Fediverse.php b/lib/Command/Fediverse.php index f4c11956..be6770b4 100644 --- a/lib/Command/Fediverse.php +++ b/lib/Command/Fediverse.php @@ -58,8 +58,8 @@ class Fediverse extends Base { parent::configure(); $this->setName('social:fediverse') ->addOption( - 'type', 't', InputArgument::OPTIONAL, - 'Change the type of access management', '' + 'type', 't', InputArgument::OPTIONAL, + 'Change the type of access management', '' ) ->addArgument('action', InputArgument::OPTIONAL, 'add/remove/test address', '') ->addArgument('address', InputArgument::OPTIONAL, 'address/host', '') diff --git a/lib/Command/MigrateAlpha3.php b/lib/Command/MigrateAlpha3.php index e59e9a99..95e74a6b 100644 --- a/lib/Command/MigrateAlpha3.php +++ b/lib/Command/MigrateAlpha3.php @@ -119,10 +119,10 @@ class MigrateAlpha3 extends Base { $this->setName('social:migrate:alpha3') ->setDescription('Trying to migrate old data to Alpha3') ->addOption( - 'remove-migrated-tables', '', InputOption::VALUE_NONE, 'Remove old table once copy is done' + 'remove-migrated-tables', '', InputOption::VALUE_NONE, 'Remove old table once copy is done' ) ->addOption( - 'force-remove-old-tables', '', InputOption::VALUE_NONE, 'Force remove old tables' + 'force-remove-old-tables', '', InputOption::VALUE_NONE, 'Force remove old tables' ); } diff --git a/lib/Command/NoteCreate.php b/lib/Command/NoteCreate.php index b0e990b9..34810e0e 100644 --- a/lib/Command/NoteCreate.php +++ b/lib/Command/NoteCreate.php @@ -96,18 +96,18 @@ class NoteCreate extends Base { parent::configure(); $this->setName('social:note:create') ->addOption( - 'replyTo', 'r', InputOption::VALUE_OPTIONAL, 'in reply to an existing thread' + 'replyTo', 'r', InputOption::VALUE_OPTIONAL, 'in reply to an existing thread' ) ->addOption( - 'to', 't', InputOption::VALUE_OPTIONAL, 'mentioning people' + 'to', 't', InputOption::VALUE_OPTIONAL, 'mentioning people' ) ->addOption( - 'type', 'y', InputOption::VALUE_OPTIONAL, - 'type: public (default), followers, unlisted, direct' + 'type', 'y', InputOption::VALUE_OPTIONAL, + 'type: public (default), followers, unlisted, direct' ) ->addOption( - 'hashtag', 'g', InputOption::VALUE_OPTIONAL, - 'hashtag, without the leading #' + 'hashtag', 'g', InputOption::VALUE_OPTIONAL, + 'hashtag, without the leading #' ) ->addArgument('user_id', InputArgument::REQUIRED, 'userId of the author') ->addArgument('content', InputArgument::REQUIRED, 'content of the post') diff --git a/lib/Command/QueueStatus.php b/lib/Command/QueueStatus.php index 67e256be..094ab68a 100644 --- a/lib/Command/QueueStatus.php +++ b/lib/Command/QueueStatus.php @@ -73,7 +73,7 @@ class QueueStatus extends Base { parent::configure(); $this->setName('social:queue:status') ->addOption( - 'token', 't', InputOption::VALUE_OPTIONAL, 'token of a request' + 'token', 't', InputOption::VALUE_OPTIONAL, 'token of a request' ) ->setDescription('Return status on the request queue'); } diff --git a/lib/Db/ActorsRequest.php b/lib/Db/ActorsRequest.php index f0b6178c..51ff87ad 100644 --- a/lib/Db/ActorsRequest.php +++ b/lib/Db/ActorsRequest.php @@ -53,13 +53,13 @@ class ActorsRequest extends ActorsRequestBuilder { ->setValue('summary', $qb->createNamedParameter($actor->getSummary())) ->setValue('avatar_version', $qb->createNamedParameter($actor->getAvatarVersion())) ->setValue( - 'preferred_username', $qb->createNamedParameter($actor->getPreferredUsername()) + 'preferred_username', $qb->createNamedParameter($actor->getPreferredUsername()) ) ->setValue('public_key', $qb->createNamedParameter($actor->getPublicKey())) ->setValue('private_key', $qb->createNamedParameter($actor->getPrivateKey())) ->setValue( - 'creation', - $qb->createNamedParameter(new DateTime('now'), IQueryBuilder::PARAM_DATE) + 'creation', + $qb->createNamedParameter(new DateTime('now'), IQueryBuilder::PARAM_DATE) ); $qb->executeStatement(); diff --git a/lib/Db/ActorsRequestBuilder.php b/lib/Db/ActorsRequestBuilder.php index ee6ad7b0..f8aa7e4b 100644 --- a/lib/Db/ActorsRequestBuilder.php +++ b/lib/Db/ActorsRequestBuilder.php @@ -121,7 +121,7 @@ class ActorsRequestBuilder extends CoreRequestBuilder { ->setLocal(true) ->setAvatarVersion($this->getInt('avatar_version', $data, -1)) ->setAccount( - $actor->getPreferredUsername() . '@' . $this->configService->getSocialAddress() + $actor->getPreferredUsername() . '@' . $this->configService->getSocialAddress() ); $actor->setUrlSocial($root) ->setUrl($actor->getId()); diff --git a/lib/Db/CacheActorsRequest.php b/lib/Db/CacheActorsRequest.php index 0027545d..4903a5f4 100644 --- a/lib/Db/CacheActorsRequest.php +++ b/lib/Db/CacheActorsRequest.php @@ -59,7 +59,7 @@ class CacheActorsRequest extends CacheActorsRequestBuilder { ->setValue('featured', $qb->createNamedParameter($actor->getFeatured())) ->setValue('url', $qb->createNamedParameter($actor->getUrl())) ->setValue( - 'preferred_username', $qb->createNamedParameter($actor->getPreferredUsername()) + 'preferred_username', $qb->createNamedParameter($actor->getPreferredUsername()) ) ->setValue('name', $qb->createNamedParameter($actor->getName())) ->setValue('summary', $qb->createNamedParameter($actor->getSummary())) @@ -112,7 +112,7 @@ class CacheActorsRequest extends CacheActorsRequestBuilder { ->set('featured', $qb->createNamedParameter($actor->getFeatured())) ->set('url', $qb->createNamedParameter($actor->getUrl())) ->set( - 'preferred_username', $qb->createNamedParameter($actor->getPreferredUsername()) + 'preferred_username', $qb->createNamedParameter($actor->getPreferredUsername()) ) ->set('name', $qb->createNamedParameter($actor->getName())) ->set('summary', $qb->createNamedParameter($actor->getSummary())) diff --git a/lib/Db/ClientRequest.php b/lib/Db/ClientRequest.php index 162caada..f6432882 100644 --- a/lib/Db/ClientRequest.php +++ b/lib/Db/ClientRequest.php @@ -56,7 +56,7 @@ class ClientRequest extends ClientRequestBuilder { $qb->setValue('app_name', $qb->createNamedParameter($client->getAppName())) ->setValue('app_website', $qb->createNamedParameter($client->getAppWebsite())) ->setValue( - 'app_redirect_uris', $qb->createNamedParameter(json_encode($client->getAppRedirectUris())) + 'app_redirect_uris', $qb->createNamedParameter(json_encode($client->getAppRedirectUris())) ) ->setValue('app_client_id', $qb->createNamedParameter($client->getAppClientId())) ->setValue('app_client_secret', $qb->createNamedParameter($client->getAppClientSecret())) diff --git a/lib/Db/CoreRequestBuilder.php b/lib/Db/CoreRequestBuilder.php index 1b5a73ba..012b0e9a 100644 --- a/lib/Db/CoreRequestBuilder.php +++ b/lib/Db/CoreRequestBuilder.php @@ -1054,8 +1054,8 @@ class CoreRequestBuilder { ->selectAlias($prefix . '_f.follow_id', $prefix . '_follow_id') ->selectAlias($prefix . '_f.creation', $prefix . '_creation') ->leftJoin( - $this->defaultSelectAlias, CoreRequestBuilder::TABLE_FOLLOWS, $prefix . '_f', - $andX + $this->defaultSelectAlias, CoreRequestBuilder::TABLE_FOLLOWS, $prefix . '_f', + $andX ); } diff --git a/lib/Db/RequestQueueRequest.php b/lib/Db/RequestQueueRequest.php index 9cb1f908..119dd88d 100644 --- a/lib/Db/RequestQueueRequest.php +++ b/lib/Db/RequestQueueRequest.php @@ -66,9 +66,9 @@ class RequestQueueRequest extends RequestQueueRequestBuilder { ->setValue('author', $qb->createNamedParameter($queue->getAuthor())) ->setValue('activity', $qb->createNamedParameter($queue->getActivity())) ->setValue( - 'instance', $qb->createNamedParameter( - json_encode($queue->getInstance(), JSON_UNESCAPED_SLASHES) - ) + 'instance', $qb->createNamedParameter( + json_encode($queue->getInstance(), JSON_UNESCAPED_SLASHES) + ) ) ->setValue('priority', $qb->createNamedParameter($queue->getPriority())) ->setValue('status', $qb->createNamedParameter($queue->getStatus())) @@ -133,8 +133,8 @@ class RequestQueueRequest extends RequestQueueRequestBuilder { $qb = $this->getRequestQueueUpdateSql(); $qb->set('status', $qb->createNamedParameter(RequestQueue::STATUS_RUNNING)) ->set( - 'last', - $qb->createNamedParameter(new DateTime('now'), IQueryBuilder::PARAM_DATE) + 'last', + $qb->createNamedParameter(new DateTime('now'), IQueryBuilder::PARAM_DATE) ); $this->limitToId($qb, $queue->getId()); $this->limitToStatus($qb, RequestQueue::STATUS_STANDBY); diff --git a/lib/Db/SocialCrossQueryBuilder.php b/lib/Db/SocialCrossQueryBuilder.php index 3bc16b12..830d6146 100644 --- a/lib/Db/SocialCrossQueryBuilder.php +++ b/lib/Db/SocialCrossQueryBuilder.php @@ -183,8 +183,8 @@ class SocialCrossQueryBuilder extends SocialCoreQueryBuilder { ->selectAlias('cd.error', 'cachedocument_error') ->selectAlias('cd.creation', 'cachedocument_creation') ->leftJoin( - $this->getDefaultSelectAlias(), CoreRequestBuilder::TABLE_CACHE_DOCUMENTS, 'cd', - $expr->eq($func->lower($pf . '.' . $fieldDocumentId), $func->lower('cd.id')) + $this->getDefaultSelectAlias(), CoreRequestBuilder::TABLE_CACHE_DOCUMENTS, 'cd', + $expr->eq($func->lower($pf . '.' . $fieldDocumentId), $func->lower('cd.id')) ); } diff --git a/lib/Db/StreamActionsRequest.php b/lib/Db/StreamActionsRequest.php index cbea36a0..c228f7bb 100644 --- a/lib/Db/StreamActionsRequest.php +++ b/lib/Db/StreamActionsRequest.php @@ -56,9 +56,9 @@ class StreamActionsRequest extends StreamActionsRequestBuilder { ->setValue('stream_id', $qb->createNamedParameter($action->getStreamId())) ->setValue('stream_id_prim', $qb->createNamedParameter($this->prim($action->getStreamId()))) ->setValue( - 'values', $qb->createNamedParameter( - json_encode($values, JSON_UNESCAPED_SLASHES) - ) + 'values', $qb->createNamedParameter( + json_encode($values, JSON_UNESCAPED_SLASHES) + ) ) ->setValue('liked', $qb->createNamedParameter(($liked) ? 1 : 0)) ->setValue('boosted', $qb->createNamedParameter(($boosted) ? 1 : 0)) diff --git a/lib/Db/StreamQueueRequest.php b/lib/Db/StreamQueueRequest.php index 1bfadf32..0ad3855e 100644 --- a/lib/Db/StreamQueueRequest.php +++ b/lib/Db/StreamQueueRequest.php @@ -110,8 +110,8 @@ class StreamQueueRequest extends StreamQueueRequestBuilder { $qb = $this->getStreamQueueUpdateSql(); $qb->set('status', $qb->createNamedParameter(StreamQueue::STATUS_RUNNING)) ->set( - 'last', - $qb->createNamedParameter(new DateTime('now'), IQueryBuilder::PARAM_DATE) + 'last', + $qb->createNamedParameter(new DateTime('now'), IQueryBuilder::PARAM_DATE) ); $this->limitToId($qb, $queue->getId()); $this->limitToStatus($qb, StreamQueue::STATUS_STANDBY); diff --git a/lib/Db/StreamRequest.php b/lib/Db/StreamRequest.php index 5da6c922..ce73b640 100644 --- a/lib/Db/StreamRequest.php +++ b/lib/Db/StreamRequest.php @@ -77,9 +77,9 @@ class StreamRequest extends StreamRequestBuilder { /** @var Note $stream */ $qb->setValue('hashtags', $qb->createNamedParameter(json_encode($stream->getHashtags()))) ->setValue( - 'attachments', $qb->createNamedParameter( - json_encode($stream->getAttachments(), JSON_UNESCAPED_SLASHES) - ) + 'attachments', $qb->createNamedParameter( + json_encode($stream->getAttachments(), JSON_UNESCAPED_SLASHES) + ) ); } @@ -707,19 +707,19 @@ class StreamRequest extends StreamRequestBuilder { ->setValue('subtype', $qb->createNamedParameter($stream->getSubType())) ->setValue('to', $qb->createNamedParameter($stream->getTo())) ->setValue( - 'to_array', $qb->createNamedParameter( - json_encode($stream->getToArray(), JSON_UNESCAPED_SLASHES) - ) + 'to_array', $qb->createNamedParameter( + json_encode($stream->getToArray(), JSON_UNESCAPED_SLASHES) + ) ) ->setValue( - 'cc', $qb->createNamedParameter( - json_encode($stream->getCcArray(), JSON_UNESCAPED_SLASHES) - ) + 'cc', $qb->createNamedParameter( + json_encode($stream->getCcArray(), JSON_UNESCAPED_SLASHES) + ) ) ->setValue( - 'bcc', $qb->createNamedParameter( - json_encode($stream->getBccArray(), JSON_UNESCAPED_SLASHES) - ) + 'bcc', $qb->createNamedParameter( + json_encode($stream->getBccArray(), JSON_UNESCAPED_SLASHES) + ) ) ->setValue('content', $qb->createNamedParameter($stream->getContent())) ->setValue('summary', $qb->createNamedParameter($stream->getSummary())) @@ -735,13 +735,13 @@ class StreamRequest extends StreamRequestBuilder { ->setValue('details', $qb->createNamedParameter(json_encode($stream->getDetailsAll()))) ->setValue('cache', $qb->createNamedParameter($cache)) ->setValue( - 'filter_duplicate', - $qb->createNamedParameter(($stream->isFilterDuplicate()) ? '1' : '0') + 'filter_duplicate', + $qb->createNamedParameter(($stream->isFilterDuplicate()) ? '1' : '0') ) ->setValue( - 'instances', $qb->createNamedParameter( - json_encode($stream->getInstancePaths(), JSON_UNESCAPED_SLASHES) - ) + 'instances', $qb->createNamedParameter( + json_encode($stream->getInstancePaths(), JSON_UNESCAPED_SLASHES) + ) ) ->setValue('local', $qb->createNamedParameter(($stream->isLocal()) ? '1' : '0')); @@ -752,8 +752,8 @@ class StreamRequest extends StreamRequestBuilder { 'published_time', $qb->createNamedParameter($dTime, IQueryBuilder::PARAM_DATE) ) ->setValue( - 'creation', - $qb->createNamedParameter(new DateTime('now'), IQueryBuilder::PARAM_DATE) + 'creation', + $qb->createNamedParameter(new DateTime('now'), IQueryBuilder::PARAM_DATE) ); } catch (Exception $e) { } diff --git a/lib/Db/StreamRequestBuilder.php b/lib/Db/StreamRequestBuilder.php index 634d2db1..5870f1f3 100644 --- a/lib/Db/StreamRequestBuilder.php +++ b/lib/Db/StreamRequestBuilder.php @@ -92,10 +92,10 @@ class StreamRequestBuilder extends CoreRequestBuilder { /** @noinspection PhpMethodParametersCountMismatchInspection */ $qb->selectDistinct('s.id') ->addSelect( - 's.nid', 's.type', 's.subtype', 's.to', 's.to_array', 's.cc', 's.bcc', 's.content', - 's.summary', 's.attachments', 's.published', 's.published_time', 's.cache', - 's.object_id', 's.attributed_to', 's.in_reply_to', 's.source', 's.local', - 's.instances', 's.creation', 's.filter_duplicate', 's.details', 's.hashtags' + 's.nid', 's.type', 's.subtype', 's.to', 's.to_array', 's.cc', 's.bcc', 's.content', + 's.summary', 's.attachments', 's.published', 's.published_time', 's.cache', + 's.object_id', 's.attributed_to', 's.in_reply_to', 's.source', 's.local', + 's.instances', 's.creation', 's.filter_duplicate', 's.details', 's.hashtags' ) ->from(self::TABLE_STREAM, 's'); diff --git a/lib/Migration/Version1000Date20221118000001.php b/lib/Migration/Version1000Date20221118000001.php index 1f44e082..a6ba7162 100644 --- a/lib/Migration/Version1000Date20221118000001.php +++ b/lib/Migration/Version1000Date20221118000001.php @@ -521,10 +521,10 @@ class Version1000Date20221118000001 extends SimpleMigrationStep { [ 'length' => 20, 'unsigned' => true -// 'autoincrement' => true, -// 'customSchemaOptions' => [ -// 'unique' => true -// ] + // 'autoincrement' => true, + // 'customSchemaOptions' => [ + // 'unique' => true + // ] ] ); $table->addColumn( diff --git a/lib/Tools/Traits/TNCLogger.php b/lib/Tools/Traits/TNCLogger.php index 2fa7d451..b58fbd9a 100644 --- a/lib/Tools/Traits/TNCLogger.php +++ b/lib/Tools/Traits/TNCLogger.php @@ -71,12 +71,12 @@ trait TNCLogger { $this->logger() ->log( - $level, - $message, - [ - 'app' => $this->setup('app'), - 'exception' => $t - ] + $level, + $message, + [ + 'app' => $this->setup('app'), + 'exception' => $t + ] ); } @@ -111,12 +111,12 @@ trait TNCLogger { $this->logger() ->log( - $level, - $message, - [ - 'app' => $this->setup('app'), - 'exception' => $e - ] + $level, + $message, + [ + 'app' => $this->setup('app'), + 'exception' => $e + ] ); } |