Yes there is a warning. However, I read and reread it and I understood it to mean that the food I had spent on training would be lost but I would recover my troops & inventory items. My food storage was full, my tc’s were empty & the warning uses the words ‘storage’ and ‘resources,’ neither of which are terms I have heard associated with anything other than food & iron. It also fails to say the critically important word ‘all’ which would at least avoid the confusion over returning at least some food in order to max out available storage.
So, the warning is, at the very least, poorly worded and therefore ambiguous. At worst it’s blatantly misleading. In either case there is ample justification to 1) reasonably consider it a bug and expect the developers to respond accordingly and/or 2) fix the wording so players are aware they are going to lose everything - resources (food), troops, inventory items.
I personally would really like my 50 troops back.