From 27489ef06f6198c88d8e27f202849af0e2799326 Mon Sep 17 00:00:00 2001 From: Jan Dittberner Date: Sat, 5 Apr 2008 18:48:33 +0000 Subject: [PATCH] r1095@denkpolster: jan | 2008-04-05 20:26:09 +0200 bugfix for sqlalchemy >= 0.4.1 * use session.save_or_update() (fixes #6) * update copyright year and add python editor comment git-svn-id: file:///home/www/usr01/svn/gnuviechadmin/trunk@251 a67ec6bc-e5d5-0310-a910-815c51eb3124 --- gnuviechadmin/backend/domain.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gnuviechadmin/backend/domain.py b/gnuviechadmin/backend/domain.py index 2935762..28c9c56 100644 --- a/gnuviechadmin/backend/domain.py +++ b/gnuviechadmin/backend/domain.py @@ -1,6 +1,7 @@ -# -*- coding: UTF-8 -*- +# -*- python -*- +# -*- coding: utf-8 -*- # -# Copyright (C) 2007 by Jan Dittberner. +# Copyright (C) 2007, 2008 by Jan Dittberner. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -230,7 +231,7 @@ class DomainEntity(BackendEntity): name = "www.%s" % (self.delegateto.name), type = 'A', content = self.ipaddr, ttl = config.getint('domain', 'defaultttl'))) - session.save(self.delegateto) + session.save_or_update(self.delegateto) session.flush() self._create_vhost_dir() self._create_log_dir()