passport-facebook-token icon indicating copy to clipboard operation
passport-facebook-token copied to clipboard

add options to not return the raw data and unpaginate profile fields

Open chkuendig opened this issue 10 years ago • 6 comments

Hi, for some reason GitHub put together both commits in one PR:

  • In some circumstances returning the raw data isn't necessary and might even be a waste of resources (e.g. when the profile will be saved to a database). This PR ads an option to disable this behavior (default behavior isn't changed)
  • For some fields Facebook doesn't return all values but paginates them (see https://developers.facebook.com/docs/graph-api/using-graph-api/v2.2#paging ). With this PR its possible to specificy these fields with the option "unpaginateFields" and they will be completely loaded. Obviously this will result in a performance hit so it should only be used when absolutely necessary (default behavior isn't changed)

Cheers

  • Chris

chkuendig avatar Mar 23 '15 09:03 chkuendig

Hey @chkuendig, would you mind adding some tests for these new options?

drudge avatar Mar 23 '15 12:03 drudge

@chkuendig seems that tests on Travis CI is successful, but anyway, it's new features. Please, cover them with tests. Thank you.

ghaiklor avatar Mar 23 '15 13:03 ghaiklor

Hi @drudge, Hi @ghaiklor i added some simple tests to cover these two options. Regards

  • Christian

chkuendig avatar Mar 23 '15 14:03 chkuendig

anything missing before you can merge this?

chkuendig avatar Apr 14 '15 11:04 chkuendig

merged recent changes in upstream.

anything holding this back from being merged?

chkuendig avatar Aug 10 '15 18:08 chkuendig

@drudge any suggestions? @chkuendig if you move unpaginate to prototype and make it clean then we can merge it.

ghaiklor avatar Aug 11 '15 06:08 ghaiklor