A task with no due date created an error when checking for completion.
This commit is contained in:
		
							parent
							
								
									82e1520cff
								
							
						
					
					
						commit
						4bad5fbd06
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		|  | @ -50,7 +50,7 @@ class Item(models.Model): | |||
|     # Model method: Has due date for an instance of this object passed? | ||||
|     def overdue_status(self): | ||||
|         "Returns whether the item's due date has passed or not." | ||||
|         if datetime.date.today() > self.due_date: | ||||
|         if self.due_date and datetime.date.today() > self.due_date: | ||||
|             return 1 | ||||
| 
 | ||||
|     def __unicode__(self): | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue