* fix: check if header exists for footer * test: add tests and refactor if statement --------- Co-authored-by: Mathias Mogensen <mathiasrieckm@gmail.com>