XF 2.1 Emacs turds screw up callbacks

I don't know where the problem lies (whether it's something in XF itself or in PHP and haven't cared to investigate it further), but I was having a devil of a time setting a callback in the ACP (in this case it was a Cron callback, but I don't think it is limited to this). It just refused to find my class. It kept saying unknown class. Finally, out of desperation, I just moved the class to a different part of the hierarchy and it worked.

Well after a "what's different about this" investigation between the working and non-working configurations, I find that the problem was the presence of what I call "emacs turds" in the directory. Emacs makes backup files of the form "filename~" when you edit a file. Apparently, having a Callback.php and Callback.php~ somehow hoses up the ACP's validation of what's a valid field. Once you get the control panel to accept it, the subsequent creation of these files doesn't seem to annoy the operation of things.

Just thought I'd let people know in case anybody else trips over it.
 
Top Bottom