@@ -34,10 +34,10 @@ internal void Execute()
3434 if ( null == msg )
3535 msg = this . CheckModuleManager ( ) ;
3636
37- if ( null == msg && SanityLib . IsEnforceable ( 1 , 12 ) )
37+ if ( null == msg )
3838 {
3939 msg = this . CheckModuleManagerConflict112 ( ) ;
40- if ( null != msg )
40+ if ( null != msg && ! Globals . Instance . IsValid )
4141 {
4242 KSPe . UI . OptionDialogBox . Option [ ] options = new KSPe . UI . OptionDialogBox . Option [ ]
4343 {
@@ -67,7 +67,8 @@ internal void Execute()
6767
6868 private void Handle ( string msg )
6969 {
70- if ( null != msg && Globals . Instance . IsValid )
70+ Log . dbg ( "Handling {0}" , msg ) ;
71+ if ( ErrorMessage . Conflict . ERR_MSG . Equals ( msg ) && Globals . Instance . IsValid )
7172 {
7273 string msg2 = this . AutoFix ( ) ;
7374 if ( null != msg2 )
@@ -88,6 +89,7 @@ private void Handle(string msg)
8889
8990 private void HandledAutoFix ( )
9091 {
92+ Log . dbg ( "HandledAutoFix" ) ;
9193 string msg = this . AutoFix ( ) ;
9294 if ( null != msg )
9395 GUI . Dialogs . ShowRebootTheGameAlertBox . Show ( msg ) ;
@@ -240,6 +242,19 @@ private string ForceMyFork()
240242 {
241243 Log . error ( "Unexpected error \" {0}\" caugh by ForceMyFork while handling {1}" , e . Message , file . Name ) ;
242244 }
245+
246+ string [ ] victims = new string [ ] { "ConfigCache" , "ConfigSHA" , "Physics" , "TechTree" } ;
247+ foreach ( string v in victims ) try
248+ {
249+ string fn = SIO . Path . Combine ( GAMEDATA , string . Format ( "{0}.{1}" , ASSEMBLY_NAME , v ) ) ;
250+ if ( SIO . File . Exists ( fn ) ) SIO . File . Delete ( fn ) ;
251+ ++ deletedFiles ;
252+ }
253+ catch ( Exception e )
254+ {
255+ Log . error ( "Unexpected error \" {0}\" caugh by ForceMyFork while handling {1}" , e . Message , v ) ;
256+ }
257+
243258 Log . detail ( "Removing Forum's MM was {0}." , 0 == deletedFiles ? "unsucessful" : "sucessful" ) ;
244259 return 0 != deletedFiles ? ErrorMessage . ERR_MM_FORUMDELETED : null ;
245260 }
0 commit comments