Avoid fifo in logic ... and some whitespace cleanup

Reusable functions for the use of browser fifo should make possible browser changes easier to implement.