Today the verb "command" commonly implies to most users that you would order someone to do something. Since a language like English cannot follow an order, you cannot command it.
But there is a somewhat old-fashioned, maybe obsolete use of the verb command which is reflected in this quote from Tennyson:
"My harp would prelude woe—I cannot all command the strings."
Here the meaning is control or mastery, which is meaning III in the Oxford English Dictionary. And with this meaning (which, in the OED, has been documented to be current until the mid 1800s), your phrase is certainly possible, and actually still (though rarely) in use today:
"It is easy to see that the idea of ‘knowing’ a language will be in the same trouble, as will the project of characterising the abilities or capacities a person must have if he commands a language." ~ Donald Davidson, A nice derangement of epitaphs
So in fact the sentence you saw is correct.