From 6457f6d14e47f60883a3731a29c9eb80d120594f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=96=9F=E9=85=8C=20=E9=B5=AC=E5=85=84?= Date: Sat, 23 May 2026 20:10:34 +0800 Subject: [PATCH] Fixed nil pointer error --- datasources/kmb/BusStop.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/datasources/kmb/BusStop.go b/datasources/kmb/BusStop.go index 79b7ffe..b77e645 100644 --- a/datasources/kmb/BusStop.go +++ b/datasources/kmb/BusStop.go @@ -43,8 +43,10 @@ func (this *BusStop) Reload() { searchData := []*string{} searchData = append(searchData, &this.BusStopId) - for _, v := range *this.Name { - searchData = append(searchData, &v) + if this.Name != nil { + for _, v := range *this.Name { + searchData = append(searchData, &v) + } } this.Key = &this.BusStopId