fixed failure to return a value from Remove