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

loopback-explorer should pick up hideRemoteMethod called after the explorer was initialized #686

Closed
bajtos opened this issue Oct 23, 2014 · 6 comments
Labels

Comments

@bajtos
Copy link
Member

bajtos commented Oct 23, 2014

// works, User.login is hidden
User.disableRemoteMethod('login', true);
app.use(explorer(app, { basePath: '/' }));

// does not work, User.login is shown in the UI
app.use(explorer(app, { basePath: '/' }));
User.disableRemoteMethod('login', true);

See also strongloop/loopback-component-explorer#22, #402 and #651

@supasate
Copy link
Contributor

supasate commented Apr 27, 2016

@bajtos Let me take this. (Anyway, I'm a beginner to this community. If I do something wrong, please advise.)

I'll send one PR to this repo to make Loopback emits 'remoteMethodDisabled' event and one PR to loopback-component-explorer to re-create the swagger object when this event fired.

@bajtos
Copy link
Member Author

bajtos commented Apr 29, 2016

I'll send one PR to this repo to make Loopback emits 'remoteMethodDisabled' event and one PR to loopback-component-explorer to re-create the swagger object when this event fired.

Awesome, thank you for the contribution. I can see the first pull request was already landed :)

@bajtos
Copy link
Member Author

bajtos commented May 2, 2016

Released in loopback@2.28.0 and loopback-component-explorer@2.5.0. Enjoy :)

@supasate
Copy link
Contributor

supasate commented May 3, 2016

@bajtos In loopback-component-explorer, should we change the loopback version in devDependency to be "^2.28.0" to make it more explicit about minimum requirement?

@bajtos
Copy link
Member Author

bajtos commented May 6, 2016

In loopback-component-explorer, should we change the loopback version in devDependency to be "^2.28.0" to make it more explicit about minimum requirement?

That's a good idea, could you please contribute that change yourself?

I am closing this issue as resolved.

@bajtos bajtos closed this as completed May 6, 2016
@supasate
Copy link
Contributor

supasate commented May 6, 2016

@bajtos Done. I made a PR at strongloop/loopback-component-explorer#159.

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

No branches or pull requests

4 participants