Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b909aae7 authored by Davis Mosenkovs's avatar Davis Mosenkovs Committed by Dees Troy
Browse files

Fix minor interface bug: No-SU prompt after no-OS prompt

When /system is wiped in TWRP and afterwards Reboot -> Recovery is selected the "No OS is installed, are you sure you want to reboot?" prompt appears. After swiping to "Reboot anyway" the "Current ROM is not rooted, do you wish to install SuperSU?" prompt appears.
This change removes "Do you wish to install SuperSU" prompt after "No OS installed" prompt.

Change-Id: Ie1157afdf5cf1cb81d6647269172d6e63af9f4b0
parent 7756859a
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -371,7 +371,7 @@ int main(int argc, char **argv) {
	TWFunc::Disable_Stock_Recovery_Replace();
	// Check for su to see if the device is rooted or not
	if (PartitionManager.Mount_By_Path("/system", false) && DataManager::GetIntValue("tw_mount_system_ro") == 0) {
		if (TWFunc::Path_Exists("/supersu/su") && !TWFunc::Path_Exists("/system/bin/su") && !TWFunc::Path_Exists("/system/xbin/su") && !TWFunc::Path_Exists("/system/bin/.ext/.su")) {
		if (TWFunc::Path_Exists("/supersu/su") && TWFunc::Path_Exists("/system/bin") && !TWFunc::Path_Exists("/system/bin/su") && !TWFunc::Path_Exists("/system/xbin/su") && !TWFunc::Path_Exists("/system/bin/.ext/.su")) {
			// Device doesn't have su installed
			DataManager::SetValue("tw_busy", 1);
			if (gui_startPage("installsu", 1, 1) != 0) {