fixes maxstate