-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
pass DS.SnapshotRecordArray to build-url-mixin buildURL #4304
pass DS.SnapshotRecordArray to build-url-mixin buildURL #4304
Conversation
@@ -47,16 +47,17 @@ export default Ember.Mixin.create({ | |||
@param {String} modelName | |||
@param {(String|Array|Object)} id single id or array of ids or query | |||
@param {(DS.Snapshot|Array)} snapshot single snapshot or array of snapshots | |||
@param {(DS.SnapshotRecordArray)} snapshotRecord single snapshotRecordArray |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you don't have to add this parameter here. It is passed as the snapshot
argument
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, I was confused with this as I wasn't sure if it was an array of Snapshot or the DS.SnapshotRecordArray. Will update...
68f33fe
to
2d6639a
Compare
@pangratz I think this is more along the lines of what you were looking for. |
😍 awesome, that was quick! Thank you very much @trevorrjohn! One tiny thing left: since this is a bugfix, can you prefix the commit with |
2d6639a
to
47b428f
Compare
no problem done. |
Hm, I may be wrong but I think the snapshot(Array) should still be passed in buildUrl, like here: Line 461 in 8959c4e
|
47b428f
to
88dd4e8
Compare
you're right, I missed that when I was removing that other code. |
Awesome catch @sly7-7. Completely missed that. Looks like this has been removed accidentally when our comments were addressed. Since no tests fail here I think that's a good sign that there is one missing, which tests this scenario. @trevorrjohn can you pass the |
@trevorrjohn nvm, just saw the test you added. That one looks good too! |
Unfortunately, I don't have the time right now, but I think there are other method where the snapshot is not passed. (here for example Line 637 in 8959c4e
|
Cool! Yeah I had it in the first commit, but accidentally ripped it out On Wed, Apr 6, 2016, 14:41 Clemens Müller notifications@github.com wrote:
|
I can look into adding it to the other methods as well. On Wed, Apr 6, 2016, 14:45 Sylvain MINA notifications@github.com wrote:
|
Let's do that in a separate PR |
OK do you want one for each method or can I do the rest in one? On Wed, Apr 6, 2016, 14:48 Clemens Müller notifications@github.com wrote:
|
Alright, so this gets tricky now, please bear with me: the tests are failing now since you added an assertion here. This assertion will fail since the snapshot array is not passed to The feature is not yet available in the So, here's what you need to do (sorry in advance 😔): pass the snapshot array here and commit this change with the message I will add a team discussion flag here to check that I am not going insane. @trevorrjohn I am very sorry for this mess, your first contribution should NOT be that complicated. If you have any further questions ping me on slack. Thanks for sticking through! You rock! Note: technically, if every commit in this PR should have a green CI, you would need to rebase the commits and put the feature commit before the bugfix..
This could be done in one PR then, but wait before the above is figured out, since I think there will be issues with the |
88dd4e8
to
3868436
Compare
I discussed this with @bmac and the approach of 2 commits is the way to go here. Thanks @trevorrjohn once again for tackling this and thanks @sly7-7 for your 👀 here! Much appreciated. Regarding "passing snapshot/snapshots" to |
See discussion: #4302