Study: Depression may be both a risk factor and consequence of diabetes