close to religion working, just some minor regex issues