use dotclear method to check version
This commit is contained in:
parent
cd0fbd47b0
commit
e538e23c93
11
_install.php
11
_install.php
@ -16,10 +16,9 @@ if (!defined('DC_CONTEXT_ADMIN')) {
|
||||
|
||||
try {
|
||||
# Compare versions
|
||||
if (version_compare(
|
||||
dcCore::app()->getVersion('kUtRL'),
|
||||
dcCore::app()->plugins->moduleInfo('kUtRL', 'version'),
|
||||
'>='
|
||||
if (!dcCore::app()->newVersion(
|
||||
basename(__DIR__),
|
||||
dcCore::app()->plugins->moduleInfo(basename(__DIR__), 'version')
|
||||
)) {
|
||||
return null;
|
||||
}
|
||||
@ -47,8 +46,8 @@ try {
|
||||
$changes = $ti->synchronize($t);
|
||||
|
||||
# Settings
|
||||
dcCore::app()->blog->settings->addNamespace('kUtRL');
|
||||
$s = dcCore::app()->blog->settings->kUtRL;
|
||||
dcCore::app()->blog->settings->addNamespace(basename(__DIR__));
|
||||
$s = dcCore::app()->blog->settings->__get(basename(__DIR__));
|
||||
$s->put('kutrl_active', false, 'boolean', 'Enabled kutrl plugin', false, true);
|
||||
$s->put('kutrl_plugin_service', 'default', 'string', 'Service to use to shorten links on third part plugins', false, true);
|
||||
$s->put('kutrl_admin_service', 'local', 'string', 'Service to use to shorten links on admin', false, true);
|
||||
|
Loading…
Reference in New Issue
Block a user