Skip to content

Commit fabbf4a

Browse files
committed
internal_link: Parse "/is/starred" internal links.
Signed-off-by: Zixuan James Li <[email protected]>
1 parent ac6b537 commit fabbf4a

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

lib/model/internal_link.dart

+2-1
Original file line numberDiff line numberDiff line change
@@ -199,10 +199,11 @@ Narrow? _interpretNarrowSegments(List<String> segments, PerAccountStore store) {
199199
switch (isElementOperands.single) {
200200
case IsOperand.mentioned:
201201
return const MentionsNarrow();
202+
case IsOperand.starred:
203+
return const StarredMessagesNarrow();
202204
case IsOperand.dm:
203205
case IsOperand.private:
204206
case IsOperand.alerted:
205-
case IsOperand.starred:
206207
case IsOperand.followed:
207208
case IsOperand.resolved:
208209
case IsOperand.unread:

test/model/internal_link_test.dart

+2-1
Original file line numberDiff line numberDiff line change
@@ -242,10 +242,11 @@ void main() {
242242
switch (operand) {
243243
case IsOperand.mentioned:
244244
testCases = sharedCases(const MentionsNarrow());
245+
case IsOperand.starred:
246+
testCases = sharedCases(const StarredMessagesNarrow());
245247
case IsOperand.dm:
246248
case IsOperand.private:
247249
case IsOperand.alerted:
248-
case IsOperand.starred:
249250
case IsOperand.followed:
250251
case IsOperand.resolved:
251252
case IsOperand.unread:

0 commit comments

Comments
 (0)