summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBernhard Posselt <dev@bernhard-posselt.com>2014-04-09 23:08:04 +0200
committerBernhard Posselt <dev@bernhard-posselt.com>2014-04-09 23:08:04 +0200
commit2486c2547862281dacd2bc5c37861823b3beaa37 (patch)
tree6b3e9d64a9704a60dbfdffe6e0101db128ff6d04
parentb33d0cc52cec04079c50a6afe02a83e7bb1d50fd (diff)
remove check for appframework, #503
-rw-r--r--appinfo/app.php46
1 files changed, 18 insertions, 28 deletions
diff --git a/appinfo/app.php b/appinfo/app.php
index a66a828c3..33dc340ab 100644
--- a/appinfo/app.php
+++ b/appinfo/app.php
@@ -26,39 +26,29 @@ namespace OCA\News;
use \OCA\News\Core\API;
+$api = new API('news');
-// dont break owncloud when the appframework is not enabled
-if(\OCP\App::isEnabled('appframework')){
+$api->addNavigationEntry(array(
- $api = new API('news');
+ // the string under which your app will be referenced in owncloud
+ 'id' => $api->getAppName(),
- $api->addNavigationEntry(array(
+ // sorting weight for the navigation. The higher the number, the higher
+ // will it be listed in the navigation
+ 'order' => 10,
- // the string under which your app will be referenced in owncloud
- 'id' => $api->getAppName(),
+ // the route that will be shown on startup
+ 'href' => $api->linkToRoute('news.page.index'),
- // sorting weight for the navigation. The higher the number, the higher
- // will it be listed in the navigation
- 'order' => 10,
+ // the icon that will be shown in the navigation
+ // this file needs to exist in img/example.png
+ 'icon' => $api->imagePath('news.svg'),
- // the route that will be shown on startup
- 'href' => $api->linkToRoute('news.page.index'),
+ // the title of your application. This will be used in the
+ // navigation or on the settings page of your app
+ 'name' => $api->getTrans()->t('News')
- // the icon that will be shown in the navigation
- // this file needs to exist in img/example.png
- 'icon' => $api->imagePath('news.svg'),
+));
- // the title of your application. This will be used in the
- // navigation or on the settings page of your app
- 'name' => $api->getTrans()->t('News')
-
- ));
-
- $api->addRegularTask('OCA\News\Backgroundjob\Task', 'run');
- $api->connectHook('OC_User', 'pre_deleteUser',
- 'OCA\News\Hooks\User', 'deleteUser');
-
-} else {
- $msg = 'Can not enable the News app because the App Framework App is disabled';
- \OCP\Util::writeLog('news', $msg, \OCP\Util::ERROR);
-} \ No newline at end of file
+$api->addRegularTask('OCA\News\Backgroundjob\Task', 'run');
+$api->connectHook('OC_User', 'pre_deleteUser', 'OCA\News\Hooks\User', 'deleteUser');