It is almost universal in Historical beliefs that Buchanan was not only a 'Dandy' who had more than one homosexual affairs , he is also much regarded as the worst president, that is until Obama!
I'd put Pierce before Buchanan but there were a bunch of bad presidents in that period. Tyler, Taylor, Fillmore, Pierce, Buchanan. Polk was the only good one in that period, and even that's depending on which side. Post civil war wasn't much better. Johnson, Grant.
And in the modern era, we have LBJ, Carter, and Obama, Clinton a step above them when kept in check, and even the Bushes and Nixons aren't prizes.