Object input verification function created, added to other functions