Logic typo in Notice.php makes replies to group-posts always go to the group
Logic typo in Notice.php makes replies to group-posts always go to the group
| Issue ID: | 3638 |
| Issue Category: | bug |
| Component: | groups |
| Priority: | normal |
| Status: | active |
| Assigned: | rozzin |
| Version: | 1.0 |
| Keywords: | group, patch exists, reply |
There's a logic-typo in Notice::saveNew(): where it's supposed to be checking if "$reply->scope & Notice::GROUP$reply->scope & Notice::GROUP_SCOPE_SCOPE", it's checking if "$reply->scope | Notice::GROUP_SCOPE"--which is always true.
It's obviously a typo just from the weird logic, but also because it contradicts the comments explaining the intent in the same block of code.
cf. attached patch.
Also cf. issue #1098, where `replies should always go to the group(s)' was requested and got `no, we don't want that' responses.
Probably want to fix this before fixing issue #3540, also.
| Attachment | Size |
|---|---|
| group-reply-logic-typo-fix_patch.txt | 638 bytes |

Updates
#1
You're right that the logic is incorrect. I've patched this on https://freesocial.org/ but haven't actually seen it in use yet.
Are you familiar with git? There are instructions for it on http://status.net/wiki/Intro_to_using_git
It would be awesome if you could make this a merge request on Gitorious.
#2
"It would be awesome if you could make this a merge request on Gitorious."
OK. Included in: https://gitorious.org/statusnet/mainline/merge_requests/201
FYI: I maintain all of the patches that I've applied to my sites in a ".git" directoy, e.g.: http://status.hackerposse.com/.git
#3
#4
You can also subscribe to the
RSS feed for updates to this issue.