Fixed minor bugs in BLOB service and added unit tests