Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Badge Issuer and Class are unique for each awarded Badge #120

Open
bencomp opened this issue Jun 25, 2021 · 0 comments
Open

Badge Issuer and Class are unique for each awarded Badge #120

bencomp opened this issue Jun 25, 2021 · 0 comments

Comments

@bencomp
Copy link

bencomp commented Jun 25, 2021

Since #90 was resolved (thanks again!), I can import earned badges into a backpack like Badgr's. I noticed that each badge shows up as coming from a different issuer, while the badges I earned are all from Python for Everyone.

It looks like the Badge Issuer URI is indeed unique, because it includes the assertion ID (the encoded badge information):

$badge_issuer = $CFG->wwwroot . "/badges/badge-issuer.php?id=". $encrypted;

and in
$badge_issuer = $CFG->wwwroot . "/badges/badge-issuer.php?id=". $encrypted;

I then realised that the line

$badge_url = $CFG->wwwroot . "/badges/badge-info.php?id=". $encrypted;

makes each badge class, i.e. the type of badge, unique as well – which makes comparing badges by their URIs impossible.

Would it be possible to define a single badge issuer URI per installation and one badge class URI for each defined badge in lessons.json? I think it is likely that one installation is supported by a singe issuer and it would reduce some of the code complexity as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant