Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@aaroncox
Copy link
Contributor

Fixes #92

Change Description

Changed 3 instances where the authenticator constructors name was being used instead of the getName() method.

This prevents the UALLoggedInAuthType localStorage value from getting mangled by webpack/etc.

An example of the value getting set improperly:

image

The value shows as n (the mangled name), as opposed to anchor (the original class name or value of getName()).

This PR is a follow up for: #92, #95, and #96.

API Changes

  • API Changes

Documentation Additions

  • Documentation Additions

@jlamarr22
Copy link
Contributor

jlamarr22 commented Jun 29, 2020

@aaroncox Thanks for submitting this. There are two more references that need to be updated and the package.json needs to be bumped to release this as a patch, so I created a new PR for this here: #98

@aaroncox
Copy link
Contributor Author

@jlamarr22 Ahh good catches, I honestly didn't even notice one of those. I do wonder if there's value in having them both though. The way I interpreted these two values was that the text within the styles was more the decorative / user facing value, where as the result returned by getName() was going to be the programatic name of the authenticator itself.

For example, with our plugin we might do:

  • Style Name: Anchor Wallet (cased, spaces, user facing value)
  • getName returns: anchor (all lower case, no spaces, "slugified")

I don't know if this matters a whole lot, but figured I'd mention it as potentially a different approach.

@jlamarr22
Copy link
Contributor

@aaroncox Makes sense to me for more customization actually -- good point. If you bump this PR's version to 0.3.1, we can get it merged and released tomorrow.

@aaroncox
Copy link
Contributor Author

Done, and also included the few other tweaks you had made in your PR as well 👍

@jlamarr22 jlamarr22 changed the base branch from master to develop June 29, 2020 13:07
@jlamarr22 jlamarr22 merged commit 5950f78 into EOSIO:develop Jun 29, 2020
@prfigueroa
Copy link

Gentlemen, thank you for getting the fix in. I've tested it in the Acueos staging environment and I can confirm the issue has been fixed. Thanks.

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

Successfully merging this pull request may close these issues.

Authenticator names are being mangled by minification

3 participants