From 1c32b1ebbde9b1080a595b0672e81b6ecfbc3716 Mon Sep 17 00:00:00 2001
From: Nicolas Delaby <nicolas@nexedi.com>
Date: Wed, 12 May 2010 13:47:05 +0000
Subject: [PATCH] Simplify code

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@35220 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 product/ERP5/Document/Document.py | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/product/ERP5/Document/Document.py b/product/ERP5/Document/Document.py
index e011e81a4d..48ab205081 100644
--- a/product/ERP5/Document/Document.py
+++ b/product/ERP5/Document/Document.py
@@ -1113,12 +1113,10 @@ class Document(PermanentURLMixIn, XMLObject, UrlMixIn, CachedConvertableMixin, S
     """
       Converts the subject of the document to a textual representation.
     """
-    subject = self.getSubject()
+    subject = self.getSubject('')
     if not subject:
       # XXX not sure if this fallback is a good idea.
-      subject = self.getTitle()
-    if subject is None:
-      subject = ''
+      subject = self.getTitle('')
     return str(subject)
 
   security.declareProtected(Permissions.View, 'asText')
-- 
2.30.9