Issue #3437178 by immaculatexavier, quietone, smustgrave, alexpott: Simplify getLegacyDrupalVersion() (cherry picked from commit 48814794)