Fixed bug where all the resources were not being extracted properly.