Attempt to fix bug on line 664