DataManager Updates

The goal of this change is to make DataManager use InfoManager to reduce
code duplication.

Change-Id: Ia4f4c4324453a192995e0f442db0a03628c13e46
diff --git a/twrp-functions.cpp b/twrp-functions.cpp
index 63ed0a6..eb1f4c2 100644
--- a/twrp-functions.cpp
+++ b/twrp-functions.cpp
@@ -506,9 +506,10 @@
 // reboot: Reboot the system. Return -1 on error, no return on success
 int TWFunc::tw_reboot(RebootCommand command)
 {
+	DataManager::Flush();
+	Update_Log_File();
 	// Always force a sync before we reboot
 	sync();
-	Update_Log_File();
 
 	switch (command) {
 		case rb_current: