integrating checkin code, need to do more testing but the core is already
implemented