API page: https://api.drupal.org/api/drupal/modules!user!user.api.php/function/hoo...

The description says

If #access is defined, the method cannot be configured as default method.

but the property is called "access" without #. The # should be removed for clarification if it is wrong. It may especially lead to confusion because "#access" is common in form arrays.

CommentFileSizeAuthor
#6 2550219-6.patch768 bytesPravin Ajaaz
#4 2550219-4.patch669 bytesPravin Ajaaz
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Anybody created an issue. See original summary.

jhodgdon’s picture

Issue tags: +Novice

Thanks for filing this! I think you are correct and #access should be access without # there.

It has apparently been fixed in Drupal 8, so this is Drupal 7 only.

Pravin Ajaaz’s picture

Assigned: Unassigned » Pravin Ajaaz
Pravin Ajaaz’s picture

Assigned: Pravin Ajaaz » Unassigned
Status: Active » Needs review
FileSize
669 bytes

Patch to remove it

jhodgdon’s picture

Status: Needs review » Needs work
+++ b/modules/user/user.api.php
@@ -123,7 +123,7 @@ function hook_user_cancel($edit, $account, $method) {
+ *   a method. If access is defined, the method cannot be configured as default
  *   method.

Could we put "the" in here? "... as the default method."

Looks good otherwise!

Pravin Ajaaz’s picture

Status: Needs work » Needs review
FileSize
768 bytes

As you wish :)

Status: Needs review » Needs work

The last submitted patch, 6: 2550219-6.patch, failed testing.

jhodgdon’s picture

Issue summary: View changes
Status: Needs work » Reviewed & tested by the community

Looks good, thanks! Test fails are unrelated.

jhodgdon’s picture

The infrastructure team is looking into the test bot issue. Please do not hit "retest" yet.

Pravin Ajaaz’s picture

Ok sure, I won't

Mixologic queued 6: 2550219-6.patch for re-testing.

Status: Reviewed & tested by the community » Needs work

The last submitted patch, 6: 2550219-6.patch, failed testing.

jhodgdon’s picture

Status: Needs work » Reviewed & tested by the community

The opcode problems seem to be fixed. There was a test bot glitch (missing tables in install) in a couple of tests... that seems to be a common test bot glitch, not the new opcode problem... so setting back to RTBC and presumably the auto-testing of RTBC will eventually catch this and test again.

It's a 2-line docs patch so we don't really need the tests beyond "patch applies and doesn't break PHP syntax" anyway.

David_Rothstein’s picture

Status: Reviewed & tested by the community » Fixed

Committed to 7.x - thanks!

Status: Fixed » Closed (fixed)

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