Skip to content
This repository was archived by the owner on Sep 20, 2023. It is now read-only.

Commit b79d0aa

Browse files
author
Natalia Harateh
committed
use the result of handle(attribute:) to set shouldShowIssueOnItemSelection
1 parent 29a8d16 commit b79d0aa

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

Classes/Issues/Referenced/IssueReferencedSectionController.swift

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,12 +48,10 @@ final class IssueReferencedSectionController: ListGenericSectionController<Issue
4848
// MARK: MarkdownStyledTextViewDelegate
4949

5050
func didTap(cell: MarkdownStyledTextView, attribute: DetectedMarkdownAttribute) {
51-
if case let .username(username) = attribute {
52-
shouldShowIssueOnItemSelection = false
53-
viewController?.presentProfile(login: username)
54-
} else {
55-
viewController?.didTap(cell: cell, attribute: attribute)
51+
guard let viewController = viewController else {
52+
return
5653
}
54+
shouldShowIssueOnItemSelection = !viewController.handle(attribute: attribute)
5755
}
5856

5957
}

0 commit comments

Comments
 (0)