gk - adding handling for null headers when converting to invocation object