Issue #3291234 by yas, Xiaohua Guan: Refactor the source code based on Drupal best practices (5) (Misc)