Update to the new gv2 capability string
This commit is contained in:
parent
f2f2b20a52
commit
58af7adeaa
2 changed files with 5 additions and 5 deletions
|
@ -1905,9 +1905,9 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const hasRegisteredGV22Support = 'hasRegisteredGV22Support';
|
const hasRegisteredGV23Support = 'hasRegisteredGV23Support';
|
||||||
if (
|
if (
|
||||||
!storage.get(hasRegisteredGV22Support) &&
|
!storage.get(hasRegisteredGV23Support) &&
|
||||||
textsecure.storage.user.getUuid()
|
textsecure.storage.user.getUuid()
|
||||||
) {
|
) {
|
||||||
const server = WebAPI.connect({
|
const server = WebAPI.connect({
|
||||||
|
@ -1915,8 +1915,8 @@
|
||||||
password: PASSWORD,
|
password: PASSWORD,
|
||||||
});
|
});
|
||||||
try {
|
try {
|
||||||
await server.registerCapabilities({ 'gv2-2': true });
|
await server.registerCapabilities({ 'gv2-3': true });
|
||||||
storage.put(hasRegisteredGV22Support, true);
|
storage.put(hasRegisteredGV23Support, true);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
window.log.error(
|
window.log.error(
|
||||||
'Error: Unable to register support for GV2.',
|
'Error: Unable to register support for GV2.',
|
||||||
|
|
|
@ -1257,7 +1257,7 @@ export function initialize({
|
||||||
const { accessKey } = options;
|
const { accessKey } = options;
|
||||||
const jsonData: any = {
|
const jsonData: any = {
|
||||||
capabilities: {
|
capabilities: {
|
||||||
'gv2-2': true,
|
'gv2-3': true,
|
||||||
},
|
},
|
||||||
fetchesMessages: true,
|
fetchesMessages: true,
|
||||||
name: deviceName ? deviceName : undefined,
|
name: deviceName ? deviceName : undefined,
|
||||||
|
|
Loading…
Reference in a new issue