Adding userdata type checking.