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

Rename internally used deprecated functions #29

Merged
merged 3 commits into from
Nov 25, 2018

Conversation

stripedpajamas
Copy link
Contributor

@stripedpajamas stripedpajamas commented Nov 15, 2018

toLegacyAddress - deprecated export
parseMultiServerAddress - undeprecated since it is not exported
parseLegacyInvite - nothing changed as only the export is deprecated
parseMultiServerInvite - nothing chagned as only the export is deprecated
parseInvite - nothing changed, export+function is deprecated and it is not called internally
parseAddress - undeprecated function, deprecated export (changed internal call to call function directly)

@christianbundy
Copy link
Contributor

Nice! This looks really great. I've just had another idea, maybe hare-brained, but do we need to prepend _ to these function names? I wonder whether it would be possible to leave the functions as-is and only deprecate when the function is exported:

exports.parseAddress = deprecate('ssb-ref.parseAddress', parseAddress)
exports.parseMultiServerInvite = deprecate('ssb-ref.parseMultiServerInvite', parseMultiServerInvite)

Sorry I've just now thought of this, if you think it's a good idea but don't have the time/energy I'd be happy to pull in your commit and add my above changes. What do you think?

@stripedpajamas
Copy link
Contributor Author

That's a great idea 😄 I'll take care of it

@christianbundy
Copy link
Contributor

Looks great, thanks! Sorry this took me so long to merge, I really appreciate this change.

@christianbundy christianbundy merged commit 82da5a6 into ssbc:master Nov 25, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants