Update javadocs and apply small bug fix