Skip to content

Commit

Permalink
Merge branch 'MDL-76671-master' of https://github.com/jleyva/moodle
Browse files Browse the repository at this point in the history
  • Loading branch information
HuongNV13 committed Jan 25, 2024
2 parents aa54590 + db13a26 commit ccc9bf6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions admin/tool/mobile/launch.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,9 @@

// Check if the plugin is properly configured.
$typeoflogin = get_config('tool_mobile', 'typeoflogin');
if (empty($SESSION->justloggedin) and
$typeoflogin != tool_mobile\api::LOGIN_VIA_BROWSER and
if (empty($SESSION->justloggedin) &&
!is_enabled_auth('oauth2') &&
$typeoflogin != tool_mobile\api::LOGIN_VIA_BROWSER &&
$typeoflogin != tool_mobile\api::LOGIN_VIA_EMBEDDED_BROWSER) {
throw new moodle_exception('pluginnotenabledorconfigured', 'tool_mobile');
}
Expand Down

0 comments on commit ccc9bf6

Please sign in to comment.