Some minor bugs in REST server