It does not exactly control either. The thyroid is a gland important in the control of metabolism. It exerts effects on metabolism through the secretion of hormones, in response to signals sent from the brain, particularly from the hypothalamus.
Both, in simple terms it controls the hormones that control weight. If it is overactive people tend to be underweight and it produces too much hormones and underactive has the opposite effect.