This is a great question and there are many variables to consider.
First, I would try to evaluate whether a firm needs to modernize. Sometimes, modernization is not necessary. In other words, the outcome of modernization is not worth the cost and work. For example, if profits would not rise all that much for the modernization, why do it?
Second, the cost of the modernization is also an important consideration. For example, if the costs of the modernization is very expensive, I would think twice, unless it was absolutely necessary. Furthermore, if I did go with the modernization, then I would take many bids to get the best price.
Finally, it is worth considering whether the modernization can take place in the future with newer equipment or anything that the needs modernization. This is an important consideration, because technology develops so quickly. From this perspective, you can always modernize.