This phrase refers generally to unholy living (see Jude 1:23). The reference is not strictly to sexual licentiousness but to any form of unholy living, including lack of alertness in relation to the imminent return of Christ, and the carelessness that follows the lack of alertness.
4 Yet you have still a few names in Sardis, people who have not soiled their garments, and they will walk with me in white, for they are worthy.