I don't think this should return 'ok'. Either throw an exception or return an error.