returning the generated key values now works