We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5edc63f commit b49281cCopy full SHA for b49281c
app/models/client.rb
@@ -4,11 +4,11 @@ class Client < ActiveRecord::Base
4
belongs_to :admin
5
6
def task_list
7
- tasks = self.tasks rescue nil
+ tasks = self.tasks
8
task_list = "There are #{tasks.size} tasks to perform today."
9
if tasks.size > 0
10
tasks.each_with_index do |task, index|
11
- task_list << "#{index+1}, #{task}."
+ task_list << "Task #{index+1}, #{task.name}. "
12
end
13
14
task_list
0 commit comments