optimize OnResourceDuplicate

Optimation according Bob Ray's advice: http://forums.modx.com/thread/87517/modx--getchildids-not-working-in-onresourceduplicate-plugin#dis-post-482323