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 @@ -159,6 +159,8 @@ func (wa *WhatsAppConnector) Stop() {
159159
160160const kvWAVersion = "whatsapp_web_version"
161161
162+ var hardcodedWAVersion = store .GetWAVersion ()
163+
162164func (wa * WhatsAppConnector ) onFirstBackgroundConnect () {
163165 verStr := wa .Bridge .DB .KV .Get (wa .Bridge .BackgroundCtx , kvWAVersion )
164166 if verStr == "" {
@@ -171,7 +173,7 @@ func (wa *WhatsAppConnector) onFirstBackgroundConnect() {
171173 return
172174 }
173175 wa .Bridge .Log .Debug ().
174- Stringer ("hardcoded_version" , store . GetWAVersion () ).
176+ Stringer ("hardcoded_version" , hardcodedWAVersion ).
175177 Stringer ("cached_version" , ver ).
176178 Msg ("Using cached WhatsApp web version number" )
177179 store .SetWAVersion (ver )
@@ -184,7 +186,7 @@ func (wa *WhatsAppConnector) onFirstClientConnect() {
184186 wa .Bridge .Log .Err (err ).Msg ("Failed to get latest WhatsApp web version number" )
185187 } else {
186188 wa .Bridge .Log .Debug ().
187- Stringer ("hardcoded_version" , store . GetWAVersion () ).
189+ Stringer ("hardcoded_version" , hardcodedWAVersion ).
188190 Stringer ("latest_version" , * ver ).
189191 Msg ("Got latest WhatsApp web version number" )
190192 store .SetWAVersion (* ver )
You can’t perform that action at this time.
0 commit comments