summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Speicher <rspeicher@gmail.com>2019-02-11 22:55:51 +0000
committerRobert Speicher <rspeicher@gmail.com>2019-02-11 22:55:51 +0000
commit21bf833f989d9eb8148b54aa2b4678c0f0071868 (patch)
tree3b07e314269da43d89cbdb3ae635f0b3b8db9c00
parenta1215556ec6c5ab84862519b82cee99645dad357 (diff)
parent01835ef048ca2a22075deaa7ff0cae3b94254193 (diff)
downloadgitlab-ce-21bf833f989d9eb8148b54aa2b4678c0f0071868.tar.gz
Merge branch 'bw-review-feedback-task-list-toggle-service' into 'master'
Address review comment for app/services/task_list_toggle_service.rb Closes #57413 See merge request gitlab-org/gitlab-ce!25013
-rw-r--r--app/services/task_list_toggle_service.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/task_list_toggle_service.rb b/app/services/task_list_toggle_service.rb
index cfe187d9b12..af24bc0524c 100644
--- a/app/services/task_list_toggle_service.rb
+++ b/app/services/task_list_toggle_service.rb
@@ -33,7 +33,7 @@ class TaskListToggleService
markdown_task = source_lines[source_line_index]
# The source in the DB could be using either \n or \r\n line endings
- return unless markdown_task == line_source || markdown_task == line_source + "\r"
+ return unless markdown_task.chomp == line_source
return unless source_checkbox = Taskable::ITEM_PATTERN.match(markdown_task)
currently_checked = TaskList::Item.new(source_checkbox[1]).complete?