aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Update
diff options
context:
space:
mode:
authorHarald Eilertsen <haraldei@anduin.net>2024-03-24 09:58:21 +0000
committerMario <mario@mariovavti.com>2024-03-24 09:58:21 +0000
commit0dc959d9fe40bddce5e99b8162bb0e770fc28ed9 (patch)
tree4ad4413b0c00d1a478111b031d9de46218f31a89 /Zotlabs/Update
parentacc1834b0dc4804703610101fa95a3375649bc45 (diff)
downloadvolse-hubzilla-0dc959d9fe40bddce5e99b8162bb0e770fc28ed9.tar.gz
volse-hubzilla-0dc959d9fe40bddce5e99b8162bb0e770fc28ed9.tar.bz2
volse-hubzilla-0dc959d9fe40bddce5e99b8162bb0e770fc28ed9.zip
Deprecate *_config() functions in core.
Diffstat (limited to 'Zotlabs/Update')
-rw-r--r--Zotlabs/Update/_1103.php6
-rw-r--r--Zotlabs/Update/_1226.php7
-rw-r--r--Zotlabs/Update/_1236.php11
-rw-r--r--Zotlabs/Update/_1242.php6
-rw-r--r--Zotlabs/Update/_1243.php12
5 files changed, 25 insertions, 17 deletions
diff --git a/Zotlabs/Update/_1103.php b/Zotlabs/Update/_1103.php
index 3f9a9286c..a32c81fe9 100644
--- a/Zotlabs/Update/_1103.php
+++ b/Zotlabs/Update/_1103.php
@@ -2,13 +2,15 @@
namespace Zotlabs\Update;
+use Zotlabs\Lib\Config;
+
class _1103 {
function run() {
$x = curl_version();
if(stristr($x['ssl_version'],'openssl'))
- set_config('system','curl_ssl_ciphers','ALL:!eNULL');
+ Config::Set('system','curl_ssl_ciphers','ALL:!eNULL');
return UPDATE_SUCCESS;
}
-} \ No newline at end of file
+}
diff --git a/Zotlabs/Update/_1226.php b/Zotlabs/Update/_1226.php
index 6e5a0e319..526fc867b 100644
--- a/Zotlabs/Update/_1226.php
+++ b/Zotlabs/Update/_1226.php
@@ -2,6 +2,7 @@
namespace Zotlabs\Update;
+use Zotlabs\Lib\Config;
use Zotlabs\Lib\Libzot;
class _1226 {
@@ -17,7 +18,7 @@ class _1226 {
$r = ($r1 && $r2);
}
else {
- $r = q("ALTER TABLE `channel` ADD `channel_portable_id` char(191) NOT NULL DEFAULT '' ,
+ $r = q("ALTER TABLE `channel` ADD `channel_portable_id` char(191) NOT NULL DEFAULT '' ,
ADD INDEX `channel_portable_id` (`channel_portable_id`)");
}
@@ -52,7 +53,7 @@ class _1226 {
$rec['xchan_hash'] = $zhash;
$rec['xchan_guid_sig'] = 'sha256.' . $rec['xchan_guid_sig'];
$rec['xchan_network'] = 'zot6';
-
+
xchan_store_lowlevel($rec);
}
$x = q("select * from hubloc where hubloc_hash = '%s' and hubloc_url = '%s' limit 1",
@@ -67,7 +68,7 @@ class _1226 {
$rec['hubloc_url_sig'] = 'sha256.' . $rec['hubloc_url_sig'];
$rec['hubloc_callback'] = z_root() . '/zot';
$rec['hubloc_id_url'] = channel_url($rv);
- $rec['hubloc_site_id'] = Libzot::make_xchan_hash(z_root(),get_config('system','pubkey'));
+ $rec['hubloc_site_id'] = Libzot::make_xchan_hash(z_root(),Config::Get('system','pubkey'));
hubloc_store_lowlevel($rec);
}
}
diff --git a/Zotlabs/Update/_1236.php b/Zotlabs/Update/_1236.php
index e57338e16..b5bfdaad8 100644
--- a/Zotlabs/Update/_1236.php
+++ b/Zotlabs/Update/_1236.php
@@ -2,15 +2,16 @@
namespace Zotlabs\Update;
+use Zotlabs\Lib\Config;
use Zotlabs\Lib\Libzot;
class _1236 {
function run() {
-
- $r = q("SELECT channel.channel_address, channel.channel_hash, xchan.xchan_guid, channel.channel_pubkey, channel.channel_portable_id FROM channel
- LEFT JOIN xchan ON channel_hash = xchan_hash
- WHERE xchan.xchan_network = 'zot'
+
+ $r = q("SELECT channel.channel_address, channel.channel_hash, xchan.xchan_guid, channel.channel_pubkey, channel.channel_portable_id FROM channel
+ LEFT JOIN xchan ON channel_hash = xchan_hash
+ WHERE xchan.xchan_network = 'zot'
AND channel.channel_removed = 0"
);
@@ -102,7 +103,7 @@ class _1236 {
$rec['hubloc_url_sig'] = 'sha256.' . $rec['hubloc_url_sig'];
$rec['hubloc_callback'] = z_root() . '/zot';
$rec['hubloc_id_url'] = channel_url($rr);
- $rec['hubloc_site_id'] = Libzot::make_xchan_hash(z_root(),get_config('system','pubkey'));
+ $rec['hubloc_site_id'] = Libzot::make_xchan_hash(z_root(),Config::Get('system','pubkey'));
$hubloc = hubloc_store_lowlevel($rec);
}
diff --git a/Zotlabs/Update/_1242.php b/Zotlabs/Update/_1242.php
index c2c9a66d0..0a4265984 100644
--- a/Zotlabs/Update/_1242.php
+++ b/Zotlabs/Update/_1242.php
@@ -2,6 +2,8 @@
namespace Zotlabs\Update;
+use Zotlabs\Lib\Config;
+
class _1242 {
function run() {
@@ -10,7 +12,7 @@ class _1242 {
if ($pp['v'][0] === '{') {
$a = json_decode($pp['v'], true);
if (isset($a['encrypted'])) {
- $v = crypto_unencapsulate($a, get_config('system', 'prvkey'));
+ $v = crypto_unencapsulate($a, Config::Get('system', 'prvkey'));
set_pconfig($pp['uid'], $pp['cat'], $pp['k'], obscurify($v));
}
}
@@ -18,4 +20,4 @@ class _1242 {
return UPDATE_SUCCESS;
}
-} \ No newline at end of file
+}
diff --git a/Zotlabs/Update/_1243.php b/Zotlabs/Update/_1243.php
index 850cb1d6c..05845ad47 100644
--- a/Zotlabs/Update/_1243.php
+++ b/Zotlabs/Update/_1243.php
@@ -2,15 +2,17 @@
namespace Zotlabs\Update;
+use Zotlabs\Lib\Config;
+
class _1243 {
function run() {
-
- $x = get_config('system','filesystem_storage_thumbnails');
- del_config('system','filesystem_storage_thumbnails');
+
+ $x = Config::Get('system','filesystem_storage_thumbnails');
+ Config::Delete('system','filesystem_storage_thumbnails');
if ($x !== false)
- set_config('system','photo_storage_type', intval($x));
-
+ Config::Set('system','photo_storage_type', intval($x));
+
return UPDATE_SUCCESS;
}