fix issue with trailing spaces in source definition