From e9904754c26f89b950e136a24c66eb08204c53bf Mon Sep 17 00:00:00 2001 From: Jon Tibble Date: Tue, 25 May 2010 02:39:48 +0100 Subject: [PATCH] Remove code redefinitions --- openlp/migration/migratebibles.py | 16 ---------------- openlp/migration/migratesongs.py | 15 --------------- 2 files changed, 31 deletions(-) diff --git a/openlp/migration/migratebibles.py b/openlp/migration/migratebibles.py index cad6afc3f..168511a02 100644 --- a/openlp/migration/migratebibles.py +++ b/openlp/migration/migratebibles.py @@ -35,22 +35,6 @@ from openlp.core.lib import SettingsManager from openlp.core.utils import AppLocation from openlp.plugins.bibles.lib.models import * -class BaseModel(object): - """ - BaseModel provides a base object with a set of generic functions - """ - - @classmethod - def populate(cls, **kwargs): - """ - Creates an instance of a class and populates it, returning the instance - """ - me = cls() - keys = kwargs.keys() - for key in keys: - me.__setattr__(key, kwargs[key]) - return me - class TBibleMeta(BaseModel): """ Bible Meta Data diff --git a/openlp/migration/migratesongs.py b/openlp/migration/migratesongs.py index b43b1e68a..19b77adae 100644 --- a/openlp/migration/migratesongs.py +++ b/openlp/migration/migratesongs.py @@ -75,21 +75,6 @@ temp_authors_songs_table = Table(u'songauthors_temp', metadata, Column(u'authorid', types.Integer, primary_key=True), Column(u'songid', types.Integer) ) -class BaseModel(object): - """ - BaseModel provides a base object with a set of generic functions - """ - - @classmethod - def populate(cls, **kwargs): - """ - Creates an instance of a class and populates it, returning the instance - """ - me = cls() - keys = kwargs.keys() - for key in keys: - me.__setattr__(key, kwargs[key]) - return me class TAuthor(BaseModel): """