Update extension.class.php

Fix my previous commit. Also put the results of the tests into variables so we don't need to check them again.