All this logic should shift down into the variable get condition as there's no point to grab these things if we aren't going to be using them.