It could be a chicken-and egg problem. It's hard to make much of the causal factors because other studies provide conflicting evidence, and it seems in some cases that there are confounding factors at work (for instance, one study linked low depression risk with the participants' satisfaction with their close relationships). It certainly doesn't look like religion itself is the main factor so much as things like social involvement and personal optimism, which makes it all the more interesting that now we have a study showing the opposite effect.
Examples of other studies with different results than the OP's can be found below, but otherwise just skip to the last two for a study that looks for other factors and for a review of the literature as a whole:
Most interesting are the last two, and I'll add quotations from them to indicate the most interesting stuff. The first one points out that it's not so much spirituality itself as factors like social support and general optimism that matter, and spirituality simply works through those factors. The second one points out that, while there is a difference, it's not a strong one, and the literature in general is not the tightest.
Although many studies suggest lower rates of depressive symptoms in those who report greater spirituality, few have investigated the mechanisms by which spirituality might relate to depressive symptoms... Spirituality was indirectly related to depressive symptoms. More specifically, spirituality was significantly associated with optimism and volunteering but not with social support, and optimism, volunteering and perceived social support were significantly associated with depressive symptoms. Findings present research and practice implications.
We reviewed data from approximately 80 published and unpublished studies that examined the association of religious affiliation or involvement with depressive symptoms or depressive disorder... Longitudinal research is sparse, but suggests that some forms of religious involvement might exert a protective effect against the incidence and persistence of depressive symptoms or disorders. The existing research is sufficient to encourage further investigation of the associations of religion with depressive symptoms and disorder. Religion should be measured with higher methodological standards than those that have been accepted in survey research to date.
The original study can be found here: