From 7f1d832ab5e018dc4aea4c8b82b351d070dc7d82 Mon Sep 17 00:00:00 2001
From: apemantus <david.hart@gmail.com>
Date: Mon, 17 Sep 2012 13:23:46 +0100
Subject: [PATCH] GID patch for Expire

---
 expire/expire.domain.inc | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/expire/expire.domain.inc b/expire/expire.domain.inc
index 401e9fe..9d05e51 100644
--- a/expire/expire.domain.inc
+++ b/expire/expire.domain.inc
@@ -13,13 +13,15 @@ function expire_get_domains(&$node) {
   if ($node->nid) {
     $result = db_query("SELECT gid FROM {domain_access} WHERE nid = :nid", array(':nid' => $node->nid));
     foreach ($result as $row) {
-      $domains[$gid] = $row->gid;
+      $gid = $row->gid;
+      $domains[$gid] = $gid;
     }
   }
   elseif ($node->mail && $node->name) {
     $result = db_query("SELECT domain_id FROM {domain_editor} WHERE uid = :uid", array(':uid' => $node->uid));
     foreach ($result as $row) {
-      $domains[$gid] = $row->domain_id;
+      $gid = $row->domain_id;
+      $domains[$gid] = $gid;
     }
   }
   return $domains;
--
1.7.11.msysgit.1

