Fix eternal reload on pages with no stylesheets.

This fixes test-in-console, which was never completing test runs because
the page would reload constantly (or something).