File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -242,7 +242,9 @@ export const getStreamTopicUrl = (
242
242
streamsById : Map < number , Stream > ,
243
243
) : URL => {
244
244
const maybe_get_stream_name = id => streamsById . get ( id ) ?. name ;
245
- const path = internal_url . by_stream_topic_url ( streamId , topic , maybe_get_stream_name ) ;
245
+ const encodedStreamId = internal_url . encode_stream_id ( streamId , maybe_get_stream_name ) ;
246
+ const encodedTopic = internal_url . encodeHashComponent ( topic ) ;
247
+ const path = `#narrow/stream/${ encodedStreamId } /topic/${ encodedTopic } ` ;
246
248
return new URL ( path , realm ) ;
247
249
} ;
248
250
@@ -252,7 +254,7 @@ export const getStreamUrl = (
252
254
streamsById : Map < number , Stream > ,
253
255
) : URL => {
254
256
const maybe_get_stream_name = id => streamsById . get ( streamId ) ?. name ;
255
- const path = internal_url . by_stream_url ( streamId , maybe_get_stream_name ) ;
257
+ const path = `#narrow/stream/ ${ internal_url . encode_stream_id ( streamId , maybe_get_stream_name ) } ` ;
256
258
return new URL ( path , realm ) ;
257
259
} ;
258
260
You can’t perform that action at this time.
0 commit comments