aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorM. Dent <dentm42@gmail.com>2018-09-29 00:17:55 +0200
committerM. Dent <dentm42@gmail.com>2018-09-29 00:17:55 +0200
commit5f992ffe154ed9e2b225c9a1b3d7c47d39e41d34 (patch)
treeb714359bdc9c056376c6f3780e8edb0e066bf73f /include
parent2904e58a9fea6441202d1f9f7a3304a2d2b1429c (diff)
downloadvolse-hubzilla-5f992ffe154ed9e2b225c9a1b3d7c47d39e41d34.tar.gz
volse-hubzilla-5f992ffe154ed9e2b225c9a1b3d7c47d39e41d34.tar.bz2
volse-hubzilla-5f992ffe154ed9e2b225c9a1b3d7c47d39e41d34.zip
Remove servicelevel logic
Diffstat (limited to 'include')
-rw-r--r--include/account.php13
-rw-r--r--include/bbcode.php3
-rw-r--r--include/features.php5
-rw-r--r--include/nav.php2
4 files changed, 3 insertions, 20 deletions
diff --git a/include/account.php b/include/account.php
index 51118c3c5..2ab99ce19 100644
--- a/include/account.php
+++ b/include/account.php
@@ -124,7 +124,7 @@ function account_store_lowlevel($arr) {
'account_expires' => ((array_key_exists('account_expires',$arr)) ? $arr['account_expires'] : '0001-01-01 00:00:00'),
'account_expire_notified' => ((array_key_exists('account_expire_notified',$arr)) ? $arr['account_expire_notified'] : '0001-01-01 00:00:00'),
'account_service_class' => ((array_key_exists('account_service_class',$arr)) ? $arr['account_service_class'] : ''),
- 'account_level' => ((array_key_exists('account_level',$arr)) ? $arr['account_level'] : '0'),
+ 'account_level' => '5',
'account_password_changed' => ((array_key_exists('account_password_changed',$arr)) ? $arr['account_password_changed'] : '0001-01-01 00:00:00')
];
@@ -215,7 +215,7 @@ function create_account($arr) {
'account_created' => datetime_convert(),
'account_flags' => intval($flags),
'account_roles' => intval($roles),
- 'account_level' => intval($techlevel),
+ 'account_level' => 5,
'account_expires' => $expires,
'account_service_class' => $default_service_class
]
@@ -821,13 +821,6 @@ function upgrade_bool_message($bbcode = false) {
function get_account_techlevel($account_id = 0) {
- if(! $account_id) {
- $x = \App::get_account();
- }
- else {
- $x = get_account_by_id($account_id);
- }
-
- return (($x) ? intval($x['account_level']) : 0);
+ return (5);
}
diff --git a/include/bbcode.php b/include/bbcode.php
index 6f22509e6..137e25a9c 100644
--- a/include/bbcode.php
+++ b/include/bbcode.php
@@ -968,9 +968,6 @@ function bbcode($Text, $options = []) {
$Text = preg_replace("/\[zrl\=([$URLSearchString]*)\](.*?)\[\/zrl\]/ism", '<a class="zrl" href="$1" ' . $target . ' rel="nofollow noopener" >$2</a>', $Text);
}
- if (get_account_techlevel() < 2)
- $Text = str_replace('<span class="bookmark-identifier">#^</span>', '', $Text);
-
// Perform MAIL Search
if (strpos($Text,'[/mail]') !== false) {
$Text = preg_replace("/\[mail\]([$MAILSearchString]*)\[\/mail\]/", '<a href="mailto:$1" ' . $target . ' rel="nofollow noopener" >$1</a>', $Text);
diff --git a/include/features.php b/include/features.php
index ccf3c5faf..a3395d7a8 100644
--- a/include/features.php
+++ b/include/features.php
@@ -416,8 +416,6 @@ function get_features($filtered = true, $level = (-1)) {
$arr = $x['features'];
- $techlevel = (($level >= 0) ? $level : get_account_techlevel());
-
// removed any locked features and remove the entire category if this makes it empty
if($filtered) {
@@ -428,9 +426,6 @@ function get_features($filtered = true, $level = (-1)) {
for($y = 0; $y < count($arr[$k]); $y ++) {
$disabled = false;
if(is_array($arr[$k][$y])) {
- if($arr[$k][$y][5] > $techlevel) {
- $disabled = true;
- }
if($arr[$k][$y][4] !== false) {
$disabled = true;
}
diff --git a/include/nav.php b/include/nav.php
index 988a07b7c..b5592d7aa 100644
--- a/include/nav.php
+++ b/include/nav.php
@@ -60,8 +60,6 @@ function nav($template = 'default') {
//we could additionally use this to display important system notifications e.g. for updates
));
- $techlevel = get_account_techlevel();
-
// nav links: array of array('href', 'text', 'extra css classes', 'title')
$nav = [];