Fixed another small bug in the add memory where wasn't returning correct
memory key