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

RestfulServerList and RestfulServerItem would help clean up the code a fair amount #43

Open
NightJar opened this issue Dec 5, 2017 · 3 comments

Comments

@NightJar
Copy link
Contributor

NightJar commented Dec 5, 2017

Previously started as a feature, it seems as though the intention was to have a handler that would return a list, and a handler that would return a singular item (perhaps with relations). Routes could be set up for each type of condition, and the code as a whole would become much more readable as it reduces the number of conditionals on whether or not we have a SS_List or a DataObject.

During the migration from SS3 support to SS4, the commented code and @todo items covering this were removed. This issue encapsulates the idea behind them, as I thought it seemed like a sensible idea.

@robbieaverill
Copy link
Contributor

Re-labelled as high impact

@robbieaverill
Copy link
Contributor

@NightJar do you think this should be done in the 2.0.0 milestone? It looks like those classes exist already, so if we can do this without breaking any APIs then it could be done after 2.0.0 as a minor release?

@NightJar
Copy link
Contributor Author

NightJar commented Dec 7, 2017

They did exist, but were removed as part of the upgrade as were essentially dead code.
We could leave the class files there, sure. I don't think the restructure work is a thing for now though.

We could restructure the module later quite easily, as the API wouldn't change I think - only the responsibilities of the methods within (the current RestfulServer class).
Overall post restructure the functionality would be the same. But ultimately if it means tagging a 3.0 then is there some blocker as to why this couldn't happen?

I think in actuality we'd be introducing features, which at most would only be a minor release.

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

No branches or pull requests

2 participants