Alternative solution of 427483c660 commit.

It gets the absolute path and use 'grep -E' to find if the file
path is outside of SNOTES_DB path