@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Fix some linter violations

Summary: Self-explanatory.

Test Plan: `arc lint`

Reviewers: epriestley, #blessed_reviewers

Reviewed By: epriestley, #blessed_reviewers

Subscribers: Korvin, epriestley

Differential Revision: https://secure.phabricator.com/D11142

+34 -33
+2 -2
src/applications/files/lipsum/PhabricatorFileTestDataGenerator.php
··· 4 4 extends PhabricatorTestDataGenerator { 5 5 6 6 public function generate() { 7 - $authorPHID = $this->loadPhabrictorUserPHID(); 7 + $author_phid = $this->loadPhabrictorUserPHID(); 8 8 $dimension = 1 << rand(5, 12); 9 9 $image = id(new PhabricatorLipsumMondrianArtist()) 10 10 ->generate($dimension, $dimension); ··· 13 13 array( 14 14 'name' => 'rand-'.rand(1000, 9999), 15 15 )); 16 - $file->setAuthorPHID($authorPHID); 16 + $file->setAuthorPHID($author_phid); 17 17 $file->setMimeType('image/jpeg'); 18 18 return $file->save(); 19 19 }
+4 -4
src/applications/files/storage/PhabricatorFile.php
··· 238 238 $copy_of_storage_engine = $file->getStorageEngine(); 239 239 $copy_of_storage_handle = $file->getStorageHandle(); 240 240 $copy_of_storage_format = $file->getStorageFormat(); 241 - $copy_of_byteSize = $file->getByteSize(); 242 - $copy_of_mimeType = $file->getMimeType(); 241 + $copy_of_byte_size = $file->getByteSize(); 242 + $copy_of_mime_type = $file->getMimeType(); 243 243 244 244 $new_file = PhabricatorFile::initializeNewFile(); 245 245 246 - $new_file->setByteSize($copy_of_byteSize); 246 + $new_file->setByteSize($copy_of_byte_size); 247 247 248 248 $new_file->setContentHash($hash); 249 249 $new_file->setStorageEngine($copy_of_storage_engine); 250 250 $new_file->setStorageHandle($copy_of_storage_handle); 251 251 $new_file->setStorageFormat($copy_of_storage_format); 252 - $new_file->setMimeType($copy_of_mimeType); 252 + $new_file->setMimeType($copy_of_mime_type); 253 253 $new_file->copyDimensions($file); 254 254 255 255 $new_file->readPropertiesFromParameters($params);
+2 -2
src/applications/maniphest/lipsum/PhabricatorManiphestTaskTestDataGenerator.php
··· 4 4 extends PhabricatorTestDataGenerator { 5 5 6 6 public function generate() { 7 - $authorPHID = $this->loadPhabrictorUserPHID(); 7 + $author_phid = $this->loadPhabrictorUserPHID(); 8 8 $author = id(new PhabricatorUser()) 9 - ->loadOneWhere('phid = %s', $authorPHID); 9 + ->loadOneWhere('phid = %s', $author_phid); 10 10 $task = ManiphestTask::initializeNewTask($author) 11 11 ->setSubPriority($this->generateTaskSubPriority()) 12 12 ->setTitle($this->generateTitle());
+4 -4
src/applications/phame/controller/PhameController.php
··· 37 37 38 38 foreach ($posts as $post) { 39 39 $blogger = $this->getHandle($post->getBloggerPHID())->renderLink(); 40 - $bloggerURI = $this->getHandle($post->getBloggerPHID())->getURI(); 41 - $bloggerImage = $this->getHandle($post->getBloggerPHID())->getImageURI(); 40 + $blogger_uri = $this->getHandle($post->getBloggerPHID())->getURI(); 41 + $blogger_image = $this->getHandle($post->getBloggerPHID())->getImageURI(); 42 42 43 43 $blog = null; 44 44 if ($post->getBlog()) { ··· 71 71 72 72 $story = id(new PHUIFeedStoryView()) 73 73 ->setTitle($title) 74 - ->setImage($bloggerImage) 75 - ->setImageHref($bloggerURI) 74 + ->setImage($blogger_image) 75 + ->setImageHref($blogger_uri) 76 76 ->setAppIcon('phame-dark') 77 77 ->setUser($viewer) 78 78 ->setPontification($phame_post, $phame_title);
+5 -5
src/applications/pholio/lipsum/PhabricatorPholioMockTestDataGenerator.php
··· 4 4 extends PhabricatorTestDataGenerator { 5 5 6 6 public function generate() { 7 - $authorPHID = $this->loadPhabrictorUserPHID(); 7 + $author_phid = $this->loadPhabrictorUserPHID(); 8 8 $author = id(new PhabricatorUser()) 9 - ->loadOneWhere('phid = %s', $authorPHID); 9 + ->loadOneWhere('phid = %s', $author_phid); 10 10 $mock = id(new PholioMock()) 11 - ->setAuthorPHID($authorPHID); 11 + ->setAuthorPHID($author_phid); 12 12 $content_source = PhabricatorContentSource::newForSource( 13 13 PhabricatorContentSource::SOURCE_UNKNOWN, 14 14 array()); ··· 27 27 array('=' => $this->getCCPHIDs()); 28 28 29 29 // Get Files and make Images 30 - $filePHIDS = $this->generateImages(); 30 + $file_phids = $this->generateImages(); 31 31 $files = id(new PhabricatorFileQuery()) 32 32 ->setViewer($author) 33 - ->withPHIDs($filePHIDS) 33 + ->withPHIDs($file_phids) 34 34 ->execute(); 35 35 $mock->setCoverPHID(head($files)->getPHID()); 36 36 $sequence = 0;
+2 -2
src/applications/policy/query/PhabricatorPolicyQuery.php
··· 117 117 } 118 118 119 119 public static function isGlobalPolicy($policy) { 120 - $globalPolicies = self::getGlobalPolicies(); 120 + $global_policies = self::getGlobalPolicies(); 121 121 122 - if (isset($globalPolicies[$policy])) { 122 + if (isset($global_policies[$policy])) { 123 123 return true; 124 124 } 125 125
+3 -3
src/applications/project/lipsum/PhabricatorProjectTestDataGenerator.php
··· 8 8 public function generate() { 9 9 $title = $this->generateTitle(); 10 10 $author = $this->loadPhabrictorUser(); 11 - $authorPHID = $author->getPHID(); 11 + $author_phid = $author->getPHID(); 12 12 $project = id(new PhabricatorProject()) 13 13 ->setName($title) 14 - ->setAuthorPHID($authorPHID); 14 + ->setAuthorPHID($author_phid); 15 15 16 16 $this->addTransaction( 17 17 PhabricatorProjectTransaction::TYPE_NAME, 18 18 $title); 19 19 $this->addTransaction( 20 20 PhabricatorProjectTransaction::TYPE_MEMBERS, 21 - $this->loadMembersWithAuthor($authorPHID)); 21 + $this->loadMembersWithAuthor($author_phid)); 22 22 $this->addTransaction( 23 23 PhabricatorProjectTransaction::TYPE_STATUS, 24 24 $this->generateProjectStatus());
+10 -10
src/applications/releeph/conduit/ReleephQueryRequestsConduitAPIMethod.php
··· 46 46 $query->withRequestedCommitPHIDs($requested_commit_phids); 47 47 } 48 48 49 - $releephRequests = $query->execute(); 49 + $releeph_requests = $query->execute(); 50 50 51 - foreach ($releephRequests as $releephRequest) { 52 - $branch = $releephRequest->getBranch(); 51 + foreach ($releeph_requests as $releeph_request) { 52 + $branch = $releeph_request->getBranch(); 53 53 54 - $request_commit_phid = $releephRequest->getRequestCommitPHID(); 54 + $request_commit_phid = $releeph_request->getRequestCommitPHID(); 55 55 56 - $object = $releephRequest->getRequestedObject(); 56 + $object = $releeph_request->getRequestedObject(); 57 57 if ($object instanceof DifferentialRevision) { 58 58 $object_phid = $object->getPHID(); 59 59 } else { 60 60 $object_phid = null; 61 61 } 62 62 63 - $status = $releephRequest->getStatus(); 64 - $statusName = ReleephRequestStatus::getStatusDescriptionFor($status); 65 - $url = PhabricatorEnv::getProductionURI('/RQ'.$releephRequest->getID()); 63 + $status = $releeph_request->getStatus(); 64 + $status_name = ReleephRequestStatus::getStatusDescriptionFor($status); 65 + $url = PhabricatorEnv::getProductionURI('/RQ'.$releeph_request->getID()); 66 66 67 67 $result[] = array( 68 68 'branchBasename' => $branch->getBasename(), 69 69 'branchSymbolic' => $branch->getSymbolicName(), 70 - 'requestID' => $releephRequest->getID(), 70 + 'requestID' => $releeph_request->getID(), 71 71 'revisionPHID' => $object_phid, 72 72 'status' => $status, 73 - 'statusName' => $statusName, 73 + 'status_name' => $status_name, 74 74 'url' => $url, 75 75 ); 76 76 }
+2 -1
src/applications/repository/phid/PhabricatorRepositoryRepositoryPHIDType.php
··· 66 66 if ($query->execute()) { 67 67 $objects = $query->getIdentifierMap(); 68 68 foreach ($objects as $key => $object) { 69 - foreach (idx($id_map, $key, array()) as $name) 69 + foreach (idx($id_map, $key, array()) as $name) { 70 70 $results[$name] = $object; 71 + } 71 72 } 72 73 return $results; 73 74 } else {