Changed -w behaviour to not produce empty file when not selected