fixes #155 infinate recursion error with resource dependencies