Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-44248

Download button on /badges/badge.php doesn't work

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • 2.5.5
    • 2.5.4
    • Badges
    • MOODLE_25_STABLE
    • MOODLE_25_STABLE
    • Hide

      Testing instructions are pretty much in bug description

      Show
      Testing instructions are pretty much in bug description

      Steps to reproduce are...

      1. Earn a badge.
      2. Go into your profile and click the badge.
      3. Click download.

      Expected the badge to download.

      Page reloads and nothing happens.

      Note that downloading from /badges/mybadges.php does work, it's only /badges/badge.php that doesn't work.

      The issue seems to be on (or around) line 38 of badge.php...
      if ($bake && ($badge->recipient == $USER->id)) {

      On my local installation I have changed it to...

      if ($bake && ($badge->recipient->id == $USER->id)) {

      ...which appears to have fixed it.

            ybozhko Yuliya Bozhko
            andrew@tintisha.net Andy McGill
            Petr Skoda Petr Skoda
            Damyon Wiese Damyon Wiese
            Ankit Agarwal Ankit Agarwal
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

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