Merge pull request #122 from pydata/sponsor-listing-text-is-none
Make sponsor description default empty string.
This commit is contained in:
		
						commit
						6bee00dff7
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		|  | @ -136,7 +136,7 @@ class Sponsor(models.Model): | ||||||
|     @property |     @property | ||||||
|     def listing_text(self): |     def listing_text(self): | ||||||
|         if not hasattr(self, "_listing_text"): |         if not hasattr(self, "_listing_text"): | ||||||
|             self._listing_text = None |             self._listing_text = "" | ||||||
|             # @@@ better than hard-coding a pk but still not good |             # @@@ better than hard-coding a pk but still not good | ||||||
|             benefits = self.sponsor_benefits.filter(benefit__name="Sponsor Description") |             benefits = self.sponsor_benefits.filter(benefit__name="Sponsor Description") | ||||||
|             if benefits.count(): |             if benefits.count(): | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue
	
	 Patrick Altman
						Patrick Altman