Uploaded image for project: 'Moodle app'
  1. Moodle app
  2. MOBILE-4516

Custom URL doesn't redirects if logged in

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • 4.3.0
    • Custom URL Scheme
    • MOODLE_403_STABLE

      I was integrating SSO into moodle and got a point where custom URL doesn't redirects to course if the user is already logged in with the same token.

      I have to strip out the token in order to redirect.

      I would like to keep the URL same as
      moodlemobile://https://domain.com?token=TOKEN&redirect=http://domain.com/course/view.php?id=2
      If the user isn't logged in then it should log in and redirect otherwise just redirect.

      I found this behaviour is due to same siteId for the user and site at https://github.com/moodlehq/moodleapp/blob/09a2bf3d962e2e95e67d33560d3f3646f241155a/src/core/services/urlschemes.ts#L152

       

      I would like to change and add another condition to this code if redirect is present in the url then it must redirect.

      I can bring up a PR if you like.

            Unassigned Unassigned
            pradyumnakrishna PradyumnaKrishna
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.