Here's Why You Should Quote Your Variables in Bash
nickjanetakis.com
nickjanetakis.com
[1] - https://www.shellcheck.net/
[2] - https://github.com/koalaman/shellcheck
Shellcheck is also in several yum repos such as EPEL and in homebrew for Mac.
You can add a comment in your script to exclude / ignore specific warnings. Examples are in the man page.
But it won't save you if you're on a server executing raw commands so it's still good to know about the concerns of omitting quotes.