Move relative *= dir into the for statement

There isn't much point in dedicating a line to relative *= dir when it can be executed in the for statement.