Fixed status code error if selenium or sahi driver is being used