branch: elpa/drupal-mode
commit d04b119de796ec17a5dc437e6d41896d3ebfd1db
Author: Thomas Fini Hansen <[email protected]>
Commit: Thomas Fini Hansen <[email protected]>
Properly add our checkers to flycheck-checkers instead of enforcing it.
---
drupal/flycheck.el | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)
diff --git a/drupal/flycheck.el b/drupal/flycheck.el
index 0a05c84e84..fcc44d8013 100644
--- a/drupal/flycheck.el
+++ b/drupal/flycheck.el
@@ -50,14 +50,6 @@ so no need to highlight it twice."
drupal/phpcs-standard)
;; Set the coding standard to "Drupal" (we checked that it is
;; supported above.
-
- (when drupal/flycheck-phpcs-js-and-css
- (if (and (apply 'derived-mode-p (append drupal-css-modes
drupal-js-modes))
- (flycheck-may-use-checker 'css-js-phpcs)
- )
- (set (make-local-variable 'flycheck-checker) 'css-js-phpcs)
- )
- )
(set 'flycheck-phpcs-standard drupal/phpcs-standard)
;; Flycheck will also highlight trailing whitespace as an
@@ -90,8 +82,8 @@ See URL `http://pear.php.net/package/PHP_CodeSniffer/'."
:modes '(css-mode js-mode)
:predicate '(lambda ()
(apply 'derived-mode-p (append drupal-php-modes
drupal-css-modes drupal-js-modes))))
+(add-to-list 'flycheck-checkers 'css-js-phpcs)
(provide 'drupal/flycheck)
-
;;; drupal/flycheck.el ends here