refactored global template helpers for blaze