Fix typo in ResourceSource and improve ResourceHelper