Added in some basic validation.