]> source.dussan.org Git - nextcloud-server.git/commitdiff
Add braces around single line if statements
authorBart Visscher <bartv@thisnet.nl>
Sat, 9 Feb 2013 21:43:35 +0000 (22:43 +0100)
committerBart Visscher <bartv@thisnet.nl>
Thu, 14 Feb 2013 07:36:26 +0000 (08:36 +0100)
lib/app.php

index fe381a57077ac2f22715316915acc90295aa5728..159ada958d338b81a574e8ae366c6d1c5c03ab9d 100644 (file)
@@ -168,8 +168,9 @@ class OC_App{
         * get all enabled apps
         */
        public static function getEnabledApps() {
-               if(!OC_Config::getValue('installed', false))
+               if(!OC_Config::getValue('installed', false)) {
                        return array();
+               }
                $apps=array('files');
                $query = OC_DB::prepare( 'SELECT `appid` FROM `*PREFIX*appconfig` WHERE `configkey` = \'enabled\' AND `configvalue`=\'yes\'' );
                $result=$query->execute();
@@ -346,9 +347,10 @@ class OC_App{
                        $settings[] = array( "id" => "personal", "order" => 1, "href" => OC_Helper::linkToRoute( "settings_personal" ), "name" => $l->t("Personal"), "icon" => OC_Helper::imagePath( "settings", "personal.svg" ));
 
                        // if there are some settings forms
-                       if(!empty(self::$settingsForms))
+                       if(!empty(self::$settingsForms)) {
                                // settings menu
                                $settings[]=array( "id" => "settings", "order" => 1000, "href" => OC_Helper::linkToRoute( "settings_settings" ), "name" => $l->t("Settings"), "icon" => OC_Helper::imagePath( "settings", "settings.svg" ));
+                       }
 
                        //SubAdmins are also allowed to access user management
                        if(OC_SubAdmin::isSubAdmin(OC_User::getUser())) {
@@ -395,8 +397,9 @@ class OC_App{
                }
 
                foreach(OC::$APPSROOTS as $dir) {
-                       if(isset($dir['writable']) && $dir['writable']===true)
+                       if(isset($dir['writable']) && $dir['writable']===true) {
                                return $dir['path'];
+                       }
                }
 
                OC_Log::write('core', 'No application directories are marked as writable.', OC_Log::ERROR);