http://drupal.org/project/issues/subscribe-mail/laksdjgdasl

The legacy code is trying to validate the final project arg in the URL in the form builder! Duh.

Instead of fixing this in master, we might as well fix it in '34496-flag-integration' (since it's going to conflict) and then we can roll out the fix along with all of #34496: [meta] Add Flag module to allow users to subscribe/unsubscribe without posting a comment

Comments

dawehner’s picture

Status: Active » Needs review
StatusFileSize
new1.57 KB

The patch uses the menu loader which takes care of project names etc.

Sadly i don't have a test enviroment for project + project_issue so it would be kind of cool if someone could test it.

sun’s picture

StatusFileSize
new669 bytes

Patch in #1 removes essential functionality.

Attached patch fixes it properly within limitations of Form API. The @see refers to #597280: Introduce form registry to fix various problems and increase security, which is closest existing core issue around this.

sun’s picture

Status: Needs review » Reviewed & tested by the community

Please ignore me, #1 is ready to fly. ;)

dww’s picture

Thanks to both of you for jumping in to fix this!

Apparently the "essential functionality" sun refers to is the ability to find this page via either a shortname or a nid. However, project_node_load() handles both cases, so I don't see the problem with #1 (although I haven't had a chance to test it yet). #1 certainly seems like the much more appropriate and elegant solution to this -- just let the menu system decide 404 or not and give the form builder the already-loaded project node in all cases. Of course, that's what I suggested to dereine last night when he offered to roll a patch for this, so no surprise I think that's the right approach. ;)

Oh, and yay I see sun just posted while I was writing this! ;)

dww’s picture

Status: Reviewed & tested by the community » Fixed

Yup, #1 is the way to go. Reviewed, tested, committed and pushed:

http://drupal.org/commitlog/commit/1894/825a9326e457a0dc1cf377bd4b098c94...

Thanks!
-Derek

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.