Fix pre-populated device name

This commit is contained in:
lilia 2017-04-06 17:08:08 -07:00 committed by Scott Nonnenberg
parent 32be90c728
commit 5650748961
No known key found for this signature in database
GPG key ID: A4931C09644C654B

View file

@ -35,13 +35,12 @@
var deviceName = textsecure.storage.user.getDeviceName();
if (!deviceName) {
deviceName = 'Chrome';
if (navigator.userAgent.match('Mac OS')) {
deviceName += ' on Mac';
deviceName = 'Mac';
} else if (navigator.userAgent.match('Linux')) {
deviceName += ' on Linux';
deviceName = 'Linux';
} else if (navigator.userAgent.match('Windows')) {
deviceName += ' on Windows';
deviceName = 'Windows';
}
}