Fix notice when not scanning any files Closes #5465