mirror of
https://github.com/CringeStudios/element-desktop.git
synced 2025-01-18 23:44:59 +01:00
Send the current arch when updating
This depends on further builder changes to actually place updates at this new location for both architectures.
This commit is contained in:
parent
c5dd6195f2
commit
f63436a2cb
@ -30,14 +30,14 @@ module.exports.start = function startAutoUpdate(updateBaseUrl) {
|
|||||||
// hits a URL that either gives it a 200 with some json or
|
// hits a URL that either gives it a 200 with some json or
|
||||||
// 204 No Content. On windows it takes a base path and looks for
|
// 204 No Content. On windows it takes a base path and looks for
|
||||||
// files under that path.
|
// files under that path.
|
||||||
if (process.platform === 'darwin' && process.arch === 'x64') {
|
if (process.platform === 'darwin') {
|
||||||
// include the current version in the URL we hit. Electron doesn't add
|
// include the current version in the URL we hit. Electron doesn't add
|
||||||
// it anywhere (apart from the User-Agent) so it's up to us. We could
|
// it anywhere (apart from the User-Agent) so it's up to us. We could
|
||||||
// (and previously did) just use the User-Agent, but this doesn't
|
// (and previously did) just use the User-Agent, but this doesn't
|
||||||
// rely on NSURLConnection setting the User-Agent to what we expect,
|
// rely on NSURLConnection setting the User-Agent to what we expect,
|
||||||
// and also acts as a convenient cache-buster to ensure that when the
|
// and also acts as a convenient cache-buster to ensure that when the
|
||||||
// app updates it always gets a fresh value to avoid update-looping.
|
// app updates it always gets a fresh value to avoid update-looping.
|
||||||
url = `${updateBaseUrl}macos/?localVersion=${encodeURIComponent(app.getVersion())}`;
|
url = `${updateBaseUrl}macos/${process.arch}/?localVersion=${encodeURIComponent(app.getVersion())}`;
|
||||||
} else if (process.platform === 'win32') {
|
} else if (process.platform === 'win32') {
|
||||||
url = `${updateBaseUrl}win32/${process.arch}/`;
|
url = `${updateBaseUrl}win32/${process.arch}/`;
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user