Basically trying to see if the flash folder is there. (This is because older r1 MikroTiks don’t have the flash folder.) and then if it isn’t there go about performing the next set of commands instead. Doing it hilariously wrong atm. Need help getting this right. Any help is much appreciated!
Normally the only safe way to handle things like this in scripting is to use the do { statements } on-error={ statements } construct.
Otherwise when an error occurs during expression evaluation the script simply stops, so you cannot test for conditions like nonexisting items safely.
Wish I knew this existed before I put an entire day into the previous script. Yes this makes sense. I’ll use this one instead seeing as it works as well and is less likely to do nothing.