steamutils 1.2.92 → 1.2.93
Sign up to get free protection for your applications and to get access to all the features.
- package/SteamClient.js +8 -0
- package/package.json +1 -1
package/SteamClient.js
CHANGED
@@ -1813,6 +1813,14 @@ function SteamClient({
|
|
1813
1813
|
}]
|
1814
1814
|
},
|
1815
1815
|
uploadRichPresence(appid, richPresence) {
|
1816
|
+
if (Array.isArray(richPresence)) {
|
1817
|
+
richPresence = richPresence.reduce(function (previousValue, currentValue, currentIndex, array) {
|
1818
|
+
if (currentValue.key) {
|
1819
|
+
previousValue[currentValue.key] = currentValue.value?.toString() || ''
|
1820
|
+
}
|
1821
|
+
return previousValue
|
1822
|
+
})
|
1823
|
+
}
|
1816
1824
|
steamClient.uploadRichPresence(appid, richPresence)
|
1817
1825
|
}
|
1818
1826
|
}
|