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

Create a synchronous version of init function #38

Closed
invalidred opened this issue Jan 8, 2019 · 1 comment · Fixed by #69
Closed

Create a synchronous version of init function #38

invalidred opened this issue Jan 8, 2019 · 1 comment · Fixed by #69
Milestone

Comments

@invalidred
Copy link

Currently the init function is async. I have a use case where I have the swagger file as JSON in memory. I would like to feed that in to the init function and make it synchronous.

swaggerValidator.initSync(myJsonSwaggerFile)
// other code follow.

I am finding the async version of init to be unnecessary and makes adding the validation lib to existing code base much harder.

@invalidred invalidred changed the title Create a sync version of init function Create a synchronous version of init function Jan 8, 2019
@idanto
Copy link
Contributor

idanto commented Jan 15, 2019

@invalidred sounds like a fair request, I would love to get a PR with this addition.

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