From c5c6c47f15f7354d174372ef16989bc908430fff Mon Sep 17 00:00:00 2001 From: whatever127 Date: Tue, 30 Jul 2019 19:44:14 +0200 Subject: [PATCH] Fix messed up architecture being reported to the server --- shared/main.php | 2 +- shared/requests.php | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/shared/main.php b/shared/main.php index dce5f6c..faf2fd9 100644 --- a/shared/main.php +++ b/shared/main.php @@ -16,7 +16,7 @@ limitations under the License. */ function uupApiVersion() { - return '1.25.0'; + return '1.25.1'; } require_once dirname(__FILE__).'/auths.php'; diff --git a/shared/requests.php b/shared/requests.php index 4b333df..d242947 100644 --- a/shared/requests.php +++ b/shared/requests.php @@ -22,6 +22,10 @@ function composeDeviceAttributes($flight, $ring, $build, $arch, $sku) { $flightEnabled = 1; $isRetail = 0; + if(is_array($arch)) { + $arch = $arch[0]; + } + if($ring == 'RETAIL') { $flightEnabled = 0; $isRetail = 1; @@ -58,7 +62,7 @@ function composeDeviceAttributes($flight, $ring, $build, $arch, $sku) { 'OEMModel=Largehard Device Model 42069', 'OEMModelBaseBoard=Largehard Base Board', 'OEMName_Uncleaned=Largehard Corporation', - 'OSArchitecture='.$arch[0], + 'OSArchitecture='.$arch, 'OSSkuId='.$sku, 'OSUILocale=en-US', 'OSVersion='.$build,