Fix dependency injection in flashMessages directive