line 97 can be moved into here