Plugins: Pause training - fix verification, allow user to edit should not bloc update from webservice - refs BT#16298

pull/3440/head
NicoDucou 5 years ago
parent 047dbdfb9a
commit 3fe97a28c0
  1. 3
      main/webservices/api/v2.php

@ -343,9 +343,8 @@ try {
break; break;
case Rest::UPDATE_USER_PAUSE_TRAINING: case Rest::UPDATE_USER_PAUSE_TRAINING:
$allow = api_get_plugin_setting('pausetraining', 'tool_enable') === 'true'; $allow = api_get_plugin_setting('pausetraining', 'tool_enable') === 'true';
$allowPauseFormation = api_get_plugin_setting('pausetraining', 'allow_users_to_edit_pause_formation') === 'true';
if (false === $allow || false === $allowPauseFormation) { if (false === $allow) {
throw new Exception(get_lang('Plugin configured')); throw new Exception(get_lang('Plugin configured'));
} }

Loading…
Cancel
Save