]> juplo.de Git - demos/kafka/chat/commitdiff
fix: Fixed handling of null-values for shard in chatroom-uri
authorKai Moritz <kai@juplo.de>
Sat, 23 Sep 2023 09:12:12 +0000 (11:12 +0200)
committerKai Moritz <kai@juplo.de>
Fri, 19 Sep 2025 10:20:53 +0000 (12:20 +0200)
src/app/chatrooms/chatrooms.component.html

index 76aa148d027c16d04b021755383fa9e28ff7c325..b046c28c6816158641a81677a32672b31a09c3fe 100644 (file)
@@ -3,6 +3,6 @@
     <h1 class="h5">Please Choose a Chat-Room</h1>
   </div>
   <div class="card-body d-grid gap-1">
-    <button *ngFor="let chatroom of chatrooms" routerLink="/chatroom/{{chatroom.shard}}/{{chatroom.id}}" type="button" class="btn btn-outline-primary">{{chatroom.name}}</button>
+    <button *ngFor="let chatroom of chatrooms" routerLink="/chatroom/{{chatroom.shard ? chatroom.shard : '_'}}/{{chatroom.id}}" type="button" class="btn btn-outline-primary">{{chatroom.name}}</button>
   </div>
 </div>