What I was trying to get to is:
- Work templates must have last step without directive code - otherwise it is intermediate step;
- When this last step is evaluated, system is trying to find generic location directive (without directive code);
- Using generic location directive for Put action is usually a good thing as you will always have a location rule, which you can override if you want;
So, lets imagine this is your work template:

Step 5 will not have directive code as this is the last step.
However, system will loop through all Put directives anyway. Here is, for example, what you might have:

so step 3 in the work template will be evaluated and location directive with specific directive code will be found. All PUT location directives except the last one (#50) have directive code. #50 does not have anything as shown above.
Step 5 will loop through all location directives - and will stop at #50 only. This kind of setup allows getting staging steps addressed always first, and last step will be always a final location. If you have multiple rules for final locations - there is a query that you can build on top of that, too.