Reworked for nested resources.