return type checking updated