Draft
Conversation
jtakalai
approved these changes
Aug 25, 2020
jtakalai
left a comment
There was a problem hiding this comment.
I've been thinking, new node.js utilities probably should be typescript going forward. I already wanted to do that with Data Union Server, but ended up "iterating faster" in the beginning with JS that I already knew. One year later I think TS would've made iterations faster.
|
|
||
| // Call validation logic. Throws on failure. | ||
| try { | ||
| logic.validate( |
There was a problem hiding this comment.
case for TypeScript: "logic" interface
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a new utility
joinserver.js, which DU admins can extend and run to implement custom join validation logic. Such custom logic can be used to replace the hosted app secret-based validation implemented in the centralized API.The utility ships with a dummy validation logic
hardcoded.js, which checks that the request contains one of hardcoded passphrases. It is only intended as a starting point for customization.