Skip to content

Commit

Permalink
fix board ID recognition
Browse files Browse the repository at this point in the history
  • Loading branch information
grahampugh committed Nov 14, 2024
1 parent a02208a commit ce1bd05
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion erase-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,7 @@ check_installer_is_valid() {
# 2. Grab compatible device/board IDs from com_apple_MobileAsset_MacSoftwareUpdate
compatible_device_ids=$(grep -A2 "SupportedDeviceModels" "$build_xml" | grep string | awk -F '<string>|</string>' '{ print $2 }')
# 3. Check that 1 is in 2.
if [[ ($device_id && "$compatible_device_ids" == *"$device_id"*) || ($board_id && "$compatible_device_ids" == *"$board_id") ]]; then
if [[ ($device_id && "$compatible_device_ids" == *"$device_id"*) || ($board_id && "$compatible_device_ids" == *"$board_id"*) ]]; then
writelog "[check_installer_is_valid] Installer is compatible with system"
else
writelog "[check_installer_is_valid] ERROR: Installer is incompatible with system"
Expand Down

0 comments on commit ce1bd05

Please sign in to comment.