Very minor patch, but I saw that the assignment to $table is not used anywhere. Hopefully the testbot will detect if the call to drupal_get_schema('users') was intentional.

CommentFileSizeAuthor
user_module-remove_cruft.patch547 bytespillarsdotnet
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

pillarsdotnet’s picture

Issue tags: +Quick fix, +quickfix

tagging.

bfroehle’s picture

Line that referenced $table was removed in #721436: Remove magical fairy saving of cruft from user_save().

pillarsdotnet’s picture

jhodgdon’s picture

Status: Needs review » Reviewed & tested by the community

This patch is certainly fine. $table is not used anywhere else in that function.

I guess that the call to drupal_get_schema() could have the side effect of calling all the hook_schema() and hook_schema_alter() implementations to compile the schema. However, that would happen only if the schema wasn't already cached. And anyway obviously it's not used in this function, so it should not be a problem to wait until something else needs the schema. And as noted in #2/#3, it was apparently just an oversight from a previous patch that removed the use of $table without removing the generation of it.

Dries’s picture

Status: Reviewed & tested by the community » Fixed

Good catch. Committed to CVS HEAD. Thanks.

Status: Fixed » Closed (fixed)
Issue tags: -Quick fix, -quickfix

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