Fix implemenation of name option for CLI