From e4996d4f5432657639798c1b286ee811a36e2a10 Mon Sep 17 00:00:00 2001 From: Mike Bayer Date: Mon, 8 Sep 2014 13:01:43 -0400 Subject: [PATCH] - check for None linker... --- lib/sqlalchemy/orm/attributes.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/sqlalchemy/orm/attributes.py b/lib/sqlalchemy/orm/attributes.py index 459a525392..2b4c3ec750 100644 --- a/lib/sqlalchemy/orm/attributes.py +++ b/lib/sqlalchemy/orm/attributes.py @@ -863,7 +863,7 @@ class CollectionAttributeImpl(AttributeImpl): self.copy = copy_function self.collection_factory = typecallable - if hasattr(self.collection_factory, "_sa_linker"): + if getattr(self.collection_factory, "_sa_linker", None): @event.listens_for(self, "init_collection") def link(target, collection, collection_adapter): -- 2.47.3