fixed bugs in MainHttpClient with string comparison.