Salt water was used in the past to set some organic dyes. It does not work on today's commercial dyes, which are chemical in nature. The salt doesn't hurt anything, but it also doesn't "set" any dyes in modern fabrics (unless they happen to be hand-dyed with organic substances, which is very unusual).