adding lockbox, error cleanup