And if one denies the Holy Ghost?
Only an unsaved person can “deny the Holy Ghost”. The Holy Ghost is what gives conviction of sin. An unsaved person will face this conviction at some point in their lives.
A saved person can “grieve” or “quench” the Holy Ghost by doing something that is sin or not responding to the Holy Ghost’s conviction for service, but they cannot lose the indwelling of the Holy Ghost. Many Christians are led astray through false teachers because of a lack of discernment through grieving or quenching the Holy Ghost, which is truly sad.