Homec4science

Fix "reply" link in Differential

Authored by epriestley <git@epriestley.com> on May 7 2011, 19:42.

Description

Fix "reply" link in Differential

Summary:
Fixes the issue caused by rPa0af5b66437719dba6136579c051982ab275e6a0. Prior to
that patch, isCommentInNewFile() returned $comment->getIsNewFile(). While this
was often the wrong value, it came from the database and was the integer 1 if
true.

After the patch, the function returns 'true' as a boolean, which is passed to JS
and then back to PHP, interpreted as an integer, and evaluates to 0.

To avoid this issue in general, provide an isBool() method on AphrontRequest
which interprets this correctly.

I will also revert the revert of rPa0af5b66437719dba6136579c051982ab275e6a0 when
I land this.

Test Plan:
Clicked "reply" on the right hand side of a diff, got a right-hand-side inline
comment.

Reviewed By: rm
Reviewers: tuomaspelkonen, jungejason, aran, rm
CC: simpkins, aran, epriestley, rm
Differential Revision: 250

Details

Committed
epriestley <git@epriestley.com>May 9 2011, 06:23
Pushed
aubortJan 31 2017, 17:16
Parents
rPH3ee7b5380e05: Revert "Revert "Make DifferentialChangesetParser explicitly map display to…
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPH3ab334af936d: Fix "reply" link in Differential (authored by epriestley <git@epriestley.com>).May 9 2011, 06:23