Revert "MDL-33105 flexible apply_units() function"

This reverts commit c2ba17858c1994d9654a5ca64cb9fb22780654c1.
Merge branch 'master' of github.com:MorrisR2/moodle