Fixed bug with multiple hats