aboutsummaryrefslogtreecommitdiffhomepage
path: root/plugins/wallabag
diff options
context:
space:
mode:
authorArthurHoaro <arthur@hoa.ro>2020-09-22 20:25:47 +0200
committerArthurHoaro <arthur@hoa.ro>2020-11-09 10:56:24 +0100
commit53054b2bf6a919fd4ff9b44b6ad1986f21f488b6 (patch)
tree39cad52645ce00fbf863ff8e482d10dfcbe7f26c /plugins/wallabag
parente09bb93e18a333eff8e6a4156f5b58ba9c7d25cd (diff)
downloadShaarli-53054b2bf6a919fd4ff9b44b6ad1986f21f488b6.tar.gz
Shaarli-53054b2bf6a919fd4ff9b44b6ad1986f21f488b6.tar.zst
Shaarli-53054b2bf6a919fd4ff9b44b6ad1986f21f488b6.zip
Apply PHP Code Beautifier on source code for linter automatic fixes
Diffstat (limited to 'plugins/wallabag')
-rw-r--r--plugins/wallabag/WallabagInstance.php9
-rw-r--r--plugins/wallabag/wallabag.php5
2 files changed, 8 insertions, 6 deletions
diff --git a/plugins/wallabag/WallabagInstance.php b/plugins/wallabag/WallabagInstance.php
index f4a0a92b..88f84ae3 100644
--- a/plugins/wallabag/WallabagInstance.php
+++ b/plugins/wallabag/WallabagInstance.php
@@ -1,4 +1,5 @@
1<?php 1<?php
2
2namespace Shaarli\Plugin\Wallabag; 3namespace Shaarli\Plugin\Wallabag;
3 4
4/** 5/**
@@ -11,20 +12,20 @@ class WallabagInstance
11 * - key: version ID, must match plugin settings. 12 * - key: version ID, must match plugin settings.
12 * - value: version name. 13 * - value: version name.
13 */ 14 */
14 private static $wallabagVersions = array( 15 private static $wallabagVersions = [
15 1 => '1.x', 16 1 => '1.x',
16 2 => '2.x', 17 2 => '2.x',
17 ); 18 ];
18 19
19 /** 20 /**
20 * @var array Static reference to WB endpoint according to the API version. 21 * @var array Static reference to WB endpoint according to the API version.
21 * - key: version name. 22 * - key: version name.
22 * - value: endpoint. 23 * - value: endpoint.
23 */ 24 */
24 private static $wallabagEndpoints = array( 25 private static $wallabagEndpoints = [
25 '1.x' => '?plainurl=', 26 '1.x' => '?plainurl=',
26 '2.x' => 'bookmarklet?url=', 27 '2.x' => 'bookmarklet?url=',
27 ); 28 ];
28 29
29 /** 30 /**
30 * @var string Wallabag user instance URL. 31 * @var string Wallabag user instance URL.
diff --git a/plugins/wallabag/wallabag.php b/plugins/wallabag/wallabag.php
index 8cd3f4ad..f2003cb9 100644
--- a/plugins/wallabag/wallabag.php
+++ b/plugins/wallabag/wallabag.php
@@ -1,4 +1,5 @@
1<?php 1<?php
2
2/** 3/**
3 * Wallabag plugin 4 * Wallabag plugin
4 */ 5 */
@@ -18,9 +19,9 @@ function wallabag_init($conf)
18{ 19{
19 $wallabagUrl = $conf->get('plugins.WALLABAG_URL'); 20 $wallabagUrl = $conf->get('plugins.WALLABAG_URL');
20 if (empty($wallabagUrl)) { 21 if (empty($wallabagUrl)) {
21 $error = t('Wallabag plugin error: '. 22 $error = t('Wallabag plugin error: ' .
22 'Please define the "WALLABAG_URL" setting in the plugin administration page.'); 23 'Please define the "WALLABAG_URL" setting in the plugin administration page.');
23 return array($error); 24 return [$error];
24 } 25 }
25 $conf->setEmpty('plugins.WALLABAG_URL', '2'); 26 $conf->setEmpty('plugins.WALLABAG_URL', '2');
26} 27}