Refactoring + start of If-* headers handling implementation.