refactoring

refactoring for drupal