Fix for file watcher when filePath is None

This happen if you use setPlainText instead of openFile.