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

Do master query for before/afterSaveHook #959

Merged

Conversation

wangmengyan95
Copy link
Contributor

Fixes #957
We should use the master access to the query for before/afterSave hook on updating and deleting.
Otherwise, if req can not query the ParseObject, what we get in before/afterSave hook will be an incomplete ParseObject.

@codecov-io
Copy link

Current coverage is 91.42%

Merging #959 into master will not affect coverage as of fce6047

@@            master    #959   diff @@
======================================
  Files           73      73       
  Stmts         4383    4384     +1
  Branches       876     876       
  Methods          0       0       
======================================
+ Hit           4007    4008     +1
  Partial         10      10       
  Missed         366     366       

Review entire Coverage Diff as of fce6047

Powered by Codecov. Updated on successful CI builds.

@@ -693,6 +694,56 @@ describe('miscellaneous', function() {
});
});

it('test afterSave get full original object even req auth can not query it', function(done) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we use full ES6 style for this?
Arrow functions and such...

@nlutsenko
Copy link
Contributor

Looks good!
Would be amazing if you could use ES6 style in tests, but no big deal if not.

@wangmengyan95 wangmengyan95 force-pushed the wangmengyan.do_master_query_for_before/afterHook branch from 340e455 to 8ea2b61 Compare March 11, 2016 06:38
@facebook-github-bot
Copy link

@wangmengyan95 updated the pull request.

wangmengyan95 added a commit that referenced this pull request Mar 11, 2016
…y_for_before/afterHook

Do master query for before/afterSaveHook
@wangmengyan95 wangmengyan95 merged commit d42d359 into master Mar 11, 2016
@wangmengyan95 wangmengyan95 deleted the wangmengyan.do_master_query_for_before/afterHook branch March 11, 2016 06:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants