added angular global functions