Enable currency settings and sticker pack synchronization
This commit is contained in:
parent
4d15ae8a85
commit
a244d77657
|
@ -38,9 +38,7 @@ var (
|
|||
Currency = SettingField{
|
||||
reactFieldName: "currency",
|
||||
dBColumnName: "currency",
|
||||
// TODO resolve issue 6 https://github.com/status-im/status-react/pull/13053#issuecomment-1065179963
|
||||
syncProtobufFactory: &SyncProtobufFactory{
|
||||
inactive: true, // Remove after issue is resolved
|
||||
fromInterface: currencyProtobufFactory,
|
||||
fromStruct: currencyProtobufFactoryStruct,
|
||||
valueFromProtobuf: StringFromSyncProtobuf,
|
||||
|
@ -307,9 +305,7 @@ var (
|
|||
reactFieldName: "stickers/packs-installed",
|
||||
dBColumnName: "stickers_packs_installed",
|
||||
valueHandler: JSONBlobHandler,
|
||||
// TODO resolve issue 8 https://github.com/status-im/status-react/pull/13053#issuecomment-1065179963
|
||||
syncProtobufFactory: &SyncProtobufFactory{
|
||||
inactive: true, // Remove after issue is resolved
|
||||
fromInterface: stickersPacksInstalledProtobufFactory,
|
||||
fromStruct: stickersPacksInstalledProtobufFactoryStruct,
|
||||
valueFromProtobuf: BytesFromSyncProtobuf,
|
||||
|
|
|
@ -2,6 +2,7 @@ package protocol
|
|||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
|
||||
"go.uber.org/zap"
|
||||
|
||||
|
@ -89,6 +90,10 @@ func (m *Messenger) handleSyncSetting(response *MessengerResponse, syncSetting *
|
|||
return err
|
||||
}
|
||||
|
||||
if v, ok := value.([]byte); ok {
|
||||
value = json.RawMessage(v)
|
||||
}
|
||||
|
||||
response.Settings = append(response.Settings, &settings.SyncSettingField{SettingField: sf, Value: value})
|
||||
return nil
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue