Footer now updates correctly when there is an error. Background now handels json errors as well.