Add possibility of trailing whitespace and add missing -d argument