Empty header values cause PHP notice - fix