Updated source code to work with Apache 2.4