Problem/Motivation

In AuthDecorator we check if the user is blocked, by using the user.module user_is_blocked() method. We can replace it with ->isBlocked() since we are already loading the whole User object.

This is a performance improvement, since user_is_blocked() queries the database and we can get rid of that call by simply using the methods available in the User entity.

Steps to reproduce

Check AuthDecorator, line 79

Proposed resolution

Replace user_is_blocked with isBlocked() method.

Remaining tasks

User interface changes

API changes

Data model changes

Issue fork mail_login-3351260

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

nkoporec created an issue. See original summary.

nkoporec’s picture

Status: Active » Needs review

  • mqanneh committed 41583c11 on 8.x-2.x authored by nkoporec
    Issue #3351260: Replace user_is_blocked() with isBlocked() in...
mqanneh’s picture

Status: Needs review » Fixed
mqanneh’s picture

Status: Fixed » Closed (fixed)