Snoop,

You should not modify a UDF. They are designed to operate exactly as coded and you will find that unless they are broken most of us won't spend the time to help you clean up your code to make it work when that is what the UDF is for in the first place.

Please explain in more detail why or how you think the UDF is adding printers that are not already found on the system so we can help see what might be going on.

I've used the UDF in production so I know first hand that it does work so we just need to help you maybe with how you're coding or understanding it.