This word is not to be confused with this noun: had = army troops. By the way, you don’t really have to bother about the double d at the end of hadd. You can say a single d, too. If it goes along with a verb in imperative mood, we understand it’s hadd and not had anyway.