Use $log.warn instead of console