Using template filter to get more elegant