Skip to content

Commit

Permalink
no_trailing_whitespace + no_trailing_whitespace_in_comment
Browse files Browse the repository at this point in the history
  • Loading branch information
Dillon-Brown committed Jan 25, 2019
1 parent 2d243d3 commit a11f2ae
Show file tree
Hide file tree
Showing 946 changed files with 7,523 additions and 7,523 deletions.
2 changes: 1 addition & 1 deletion Api/V8/Config/routes.php
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@
)
->add($paramsMiddlewareFactory->bind(DeleteRelationShipParams::class));

// add custom routes
// add custom routes
$app->group('/custom', function () use ($app) {
$app = CustomLoader::loadCustomRoutes($app);
});
Expand Down
2 changes: 1 addition & 1 deletion Api/V8/Controller/ListViewController.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ public function __construct(ListViewService $listViewService)
}

/**
*
*
* @param Request $request
* @param Response $response
* @param array $args
Expand Down
2 changes: 1 addition & 1 deletion Api/V8/Controller/UserController.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public function __construct(UserService $userService)
}

/**
*
*
* @param Request $request
* @param Response $response
* @param array $args
Expand Down
2 changes: 1 addition & 1 deletion Api/V8/Controller/UserPreferencesController.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public function __construct(UserPreferencesService $userPreferencesService)
}

/**
*
*
* @param Request $request
* @param Response $response
* @param array $args
Expand Down
4 changes: 2 additions & 2 deletions Api/V8/Middleware/ParamsMiddleware.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ public function __invoke(Request $request, Response $httpResponse, callable $nex
$response->setStatus(400);
$msg = $exception->getMessage();
$dbg = "\nCode:" . $exception->getCode() .
"\n" . $exception->getFile() . ':' . $exception->getLine() .
"\nTrace:\n" . $exception->getTraceAsString() .
"\n" . $exception->getFile() . ':' . $exception->getLine() .
"\nTrace:\n" . $exception->getTraceAsString() .
"\n";
LoggerManager::getLogger()->fatal("API Exception detected:\nMessage was: $msg\nException details:\n$dbg");
$response->setDetail($msg);
Expand Down
2 changes: 1 addition & 1 deletion Api/V8/Param/GetUserPreferencesParams.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public function getUserId()
}

/**
*
*
* @param OptionsResolver $resolver
*/
protected function configureParameters(OptionsResolver $resolver)
Expand Down
2 changes: 1 addition & 1 deletion Api/V8/Param/ListViewColumnsParams.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public function getModuleName()
}

/**
*
*
* @param \Api\V8\Param\OptionsResolver $resolver
*/
protected function configureParameters(OptionsResolver $resolver)
Expand Down
2 changes: 1 addition & 1 deletion Api/V8/Param/ListViewSearchParams.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public function getModuleName()
}

/**
*
*
* @param OptionsResolver $resolver
*/
protected function configureParameters(OptionsResolver $resolver)
Expand Down
6 changes: 3 additions & 3 deletions Api/V8/Param/Options/Attributes.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,10 @@ public function add(OptionsResolver $resolver)
$bean = $this->beanManager->newBeanSafe($options->offsetGet('type'));

foreach ($values as $attribute => $value) {
$invalidProperty =
!property_exists($bean, $attribute) &&
$invalidProperty =
!property_exists($bean, $attribute) &&
!array_key_exists($attribute, $bean->field_defs) &&
!array_key_exists($attribute, $bean->field_name_map);
!array_key_exists($attribute, $bean->field_name_map);
if ($invalidProperty) {
throw new OutOfBoundsException(sprintf(
'Property %s in %s module is invalid',
Expand Down
2 changes: 1 addition & 1 deletion Api/V8/Service/UserService.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public function __construct(
}

/**
*
*
* @param Request $request
* @return DocumentResponse
*/
Expand Down
2 changes: 1 addition & 1 deletion HandleAjaxCall.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
require_once('ModuleInstall/PackageManager/PackageController.php');
if (!is_admin($GLOBALS['current_user'])) {
sugar_die($GLOBALS['app_strings']['ERR_NOT_ADMIN']);
}
}
$requestedMethod = $_REQUEST['method'];
$pmc = new PackageController();

Expand Down
10 changes: 5 additions & 5 deletions ModuleInstall/ModuleScanner.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,24 +16,24 @@
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address [email protected].
*
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
Expand Down
18 changes: 9 additions & 9 deletions ModuleInstall/PackageManager/metadata/listviewdefs.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,28 +40,28 @@

$listViewDefs['module_loader']['packages'] = array(
'name' => array(
'width' => '5',
'label' => 'LBL_LIST_NAME',
'width' => '5',
'label' => 'LBL_LIST_NAME',
'link' => false,
'default' => true,
'show' => true),
'show' => true),
'description' => array(
'width' => '32',
'label' => 'LBL_ML_DESCRIPTION',
'width' => '32',
'label' => 'LBL_ML_DESCRIPTION',
'default' => true,
'link' => false,
'show' => true),
);

$listViewDefs['module_loader']['releases'] = array(
'description' => array(
'width' => '32',
'label' => 'LBL_LIST_SUBJECT',
'width' => '32',
'label' => 'LBL_LIST_SUBJECT',
'default' => true,
'link' => false),
'version' => array(
'width' => '32',
'label' => 'LBL_LIST_SUBJECT',
'width' => '32',
'label' => 'LBL_LIST_SUBJECT',
'default' => true,
'link' => false),
);
10 changes: 5 additions & 5 deletions SugarSecurity.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ function scan($path= '.', $ext = '.php')
$this->scan($path .'/' . $entry);
}
if (is_file($path . '/'. $entry) && substr($entry, strlen($entry) - strlen($ext), strlen($ext)) == $ext) {
$contents = file_get_contents($path .'/'. $entry);
$contents = file_get_contents($path .'/'. $entry);
$this->scanContents($contents, $path .'/'. $entry);
}
}
Expand All @@ -91,13 +91,13 @@ function scanContents($contents, $file)
$found = '';
/*preg_match_all("'(require_once\([^\)]*\\$[^\)]*\))'si", $contents, $results, PREG_SET_ORDER);
foreach($results as $result){
$found .= "\n" . $result[0];
$found .= "\n" . $result[0];
}
$results = array();
preg_match_all("'include_once\([^\)]*\\$[^\)]*\)'si", $contents, $results, PREG_SET_ORDER);
foreach($results as $result){
$found .= "\n" . $result[0];
$found .= "\n" . $result[0];
}
*/
$results = array();
Expand Down Expand Up @@ -162,7 +162,7 @@ function display()

function save()
{
//reset($this->scanners);
//reset($this->scanners);
$name = 'SugarSecure'. time() . '.txt';
while ($this->scanners = next($this->scanners)) {
$scanner->save($name);
Expand Down
4 changes: 2 additions & 2 deletions TreeData.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
$depth=$pssplit[count($pssplit)-1];
//parmeter is surrounded by PARAMN_ and depth info.
unset($pssplit[count($pssplit)-1]);
unset($pssplit[0]);
unset($pssplit[0]);
$params1['NODES'][$depth][implode('_', $pssplit)]=$value;
} else {
if ($key=='module') {
Expand All @@ -91,7 +91,7 @@
}
}
}
}
}
$modulename=$params1['TREE']['module']; ///module is a required parameter for the tree.
require('include/modules.php');
if (!empty($modulename) && !empty($func_name) && isset($beanList[$modulename])) {
Expand Down
6 changes: 3 additions & 3 deletions data/Relationships/M2MRelationship.php
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ public function add($lhs, $rhs, $additionalFields = array())
$this->callAfterAdd($rhs, $lhs, $rhsLinkName);

/* BEGIN - SECURITY GROUPS */
} //end normal
} //end normal
/* END - SECURITY GROUPS */

return true;
Expand Down Expand Up @@ -293,7 +293,7 @@ public function remove($lhs, $rhs)
}
}
} else {
/* END - SECURITY GROUPS */
/* END - SECURITY GROUPS */
if (empty($lhs->$lhsLinkName) && !$lhs->load_relationship($lhsLinkName)) {
$GLOBALS['log']->fatal("could not load LHS $lhsLinkName");
return false;
Expand Down Expand Up @@ -338,7 +338,7 @@ public function remove($lhs, $rhs)
}
}
/* BEGIN - SECURITY GROUPS */
} //end normal
} //end normal
/* END - SECURITY GROUPS */

return true;
Expand Down
2 changes: 1 addition & 1 deletion data/Relationships/One2MRelationship.php
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ public function add($lhs, $rhs, $additionalFields = array())

/**
* Just overriding the function from M2M to prevent it from occuring
*
*
* The logic for dealing with adding self-referencing one-to-many relations is in the add() method
*/
protected function addSelfReferencing($lhs, $rhs, $additionalFields = array())
Expand Down
2 changes: 1 addition & 1 deletion include/Dashlets/DashletCacheBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@

/*********************************************************************************
* Description: Handles Generic Widgets
* Description: Handles Generic Widgets
* Portions created by SugarCRM are Copyright (C) SugarCRM, Inc.
* All Rights Reserved.
* Contributor(s): ______________________________________..
Expand Down
10 changes: 5 additions & 5 deletions include/Dashlets/DashletRssFeedTitle.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,24 +13,24 @@
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
*
* You should have received a copy of the GNU Affero General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address [email protected].
*
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
Expand Down
4 changes: 2 additions & 2 deletions include/ErrorMessage.php
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ public static function handler($message, $level = self::DEFAULT_LOG_LEVEL, $thro
}

/**
*
*
* @param string $message
* @param integer $level
*/
Expand All @@ -152,7 +152,7 @@ public static function log($message, $level = self::DEFAULT_LOG_LEVEL)
}

/**
*
*
* @param string $message
* @param integer $code
*/
Expand Down
12 changes: 6 additions & 6 deletions include/GoogleSync/GoogleSync.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,10 @@ class GoogleSync extends GoogleSyncBase

/**
* Gets the combined titles of a Meeting/Event pair for Logging
*
*
* @param Meeting $meeting The CRM Meeting
* @param \Google_Service_Calendar_Event $event The Google Event
*
*
* @return string The combined title
*/
protected function getTitle(Meeting $meeting = null, Google_Service_Calendar_Event $event = null)
Expand All @@ -86,11 +86,11 @@ protected function getTitle(Meeting $meeting = null, Google_Service_Calendar_Eve

/**
* Helper method for doSync
*
*
* @param string $action The action to take with the two events
* @param Meeting $meeting The CRM Meeting
* @param \Google_Service_Calendar_Event $event The Google Event
*
*
* @return bool Success/Failure
* @throws GoogleSyncException if $action is invalid.
* @throws GoogleSyncException if something else fails.
Expand Down Expand Up @@ -253,8 +253,8 @@ protected function setSyncUsers(&$tempData = [])
throw new GoogleSyncException('Unable to get User bean. ID was: ' . $row['id'], GoogleSyncException::UNABLE_TO_RETRIEVE_USER);
}

if ($tmp['notEmpty'] = !empty($user->getPreference('GoogleApiToken', 'GoogleSync')) &&
$tmp['decoded'] = json_decode(base64_decode($user->getPreference('GoogleApiToken', 'GoogleSync'))) &&
if ($tmp['notEmpty'] = !empty($user->getPreference('GoogleApiToken', 'GoogleSync')) &&
$tmp['decoded'] = json_decode(base64_decode($user->getPreference('GoogleApiToken', 'GoogleSync'))) &&
$tmp['syncPref'] = $user->getPreference('syncGCal', 'GoogleSync')
) {
if ($tmp['added'] = $this->addUser($user->id, $user->full_name)) {
Expand Down
10 changes: 5 additions & 5 deletions include/GoogleSync/GoogleSyncBase.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ class GoogleSyncBase

/**
* Class Constructor
*
*
* @param array $sugarConfig - using $sugar_config as a dependency
*/
public function __construct($sugarConfig)
Expand Down Expand Up @@ -237,9 +237,9 @@ protected function getGoogleClient($accessToken)

/**
* Initialize Service for User
*
*
* @param string $id The SuiteCRM user id
*
*
* @return bool Success/Failure
* @throws GoogleSyncException if $id is invalid
* @throws GoogleSyncException if unable to retrive the user
Expand Down Expand Up @@ -353,7 +353,7 @@ protected function setUsersGoogleCalendar()
* find the id of the 'SuiteCRM' calendar ... in the future, this will return the calendar of the users choosing.
*
* @param Google_Service_Calendar_CalendarList $calendarList
*
*
* @return string|null Matching Google Calendar ID or null.
*/
protected function getSuiteCRMCalendar(Google_Service_Calendar_CalendarList $calendarList)
Expand Down Expand Up @@ -766,7 +766,7 @@ protected function updateSuitecrmMeetingEvent(Meeting $event_local, Google_Servi
}
if (!$start instanceof Google_Service_Calendar_EventDateTime) {
throw new GoogleSyncException(
'GoogleSyncBase is trying to get "start" as Google_Service_Calendar_EventDateTime but it is incorrect, ' .
'GoogleSyncBase is trying to get "start" as Google_Service_Calendar_EventDateTime but it is incorrect, ' .
gettype($start) . ' given.', GoogleSyncException::NO_REMOVE_EVENT_START_IS_INCORRECT);
}
$starttime = strtotime($start->getDateTime());
Expand Down
Loading

0 comments on commit a11f2ae

Please sign in to comment.