implemented changes to make it scala 2.10 compatible