fix(build): import waWa6 for ClientPayload_UserAgent_AppVersion
maintained-develop (after PR #1) did not compile: whatsmeow.go referenced an undefined waProto package. The AppVersion type lives in go.mau.fi/whatsmeow/proto/waWa6. Also gofmt the file. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
4998ab3d45
commit
abaac8eb93
1 file changed
+3
-3
@@ -1,13 +1,13 @@
|
||||
package whatsmeow_service
|
||||
|
||||
import (
|
||||
"github.com/evolution-foundation/evolution-go/pkg/safemap"
|
||||
"bytes"
|
||||
"context"
|
||||
"database/sql"
|
||||
"encoding/base64"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"github.com/evolution-foundation/evolution-go/pkg/safemap"
|
||||
"image/png"
|
||||
"io"
|
||||
"math/rand"
|
||||
@@ -29,6 +29,7 @@ import (
|
||||
"go.mau.fi/whatsmeow/appstate"
|
||||
"go.mau.fi/whatsmeow/proto/waCompanionReg"
|
||||
"go.mau.fi/whatsmeow/proto/waE2E"
|
||||
"go.mau.fi/whatsmeow/proto/waWa6"
|
||||
"go.mau.fi/whatsmeow/store"
|
||||
"go.mau.fi/whatsmeow/store/sqlstore"
|
||||
"go.mau.fi/whatsmeow/types"
|
||||
@@ -320,7 +321,6 @@ func (w whatsmeowService) ForceUpdateJid(instanceId string, number string) error
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
// getSharedSQLStoreContainer returns the process-wide whatsmeow sqlstore.Container.
|
||||
// PostgresAuthDB reuses the pooled authDB from initPostgresAuthDB (Upgrade once).
|
||||
// The Users/GORM database is intentionally separate and never passed here.
|
||||
@@ -561,7 +561,7 @@ func (w whatsmeowService) StartClient(cd *ClientData) {
|
||||
waVer := store.WAVersionContainer{uint32(version.Major), uint32(version.Minor), uint32(version.Patch)}
|
||||
store.SetWAVersion(waVer)
|
||||
if store.BaseClientPayload != nil && store.BaseClientPayload.UserAgent != nil {
|
||||
store.BaseClientPayload.UserAgent.AppVersion = &waProto.ClientPayload_UserAgent_AppVersion{
|
||||
store.BaseClientPayload.UserAgent.AppVersion = &waWa6.ClientPayload_UserAgent_AppVersion{
|
||||
Primary: proto.Uint32(uint32(version.Major)),
|
||||
Secondary: proto.Uint32(uint32(version.Minor)),
|
||||
Tertiary: proto.Uint32(uint32(version.Patch)),
|
||||
|
||||
Reference in new issue
Block a user