Fixed issue #244 (relabelling now preserves empty input slots)