add some basic validation