i don't like the default function snippet
model validation snippet