update .gitignore to include library/metabox
fix fatal error caused by "add parent classes for menu items" function

it was working fine on the live site but was causing a fatal error on my local environment with MAMP.

the original snippet was badly written. i checked the reference url and sure enough, a cleaner version replaced the original snippet i grabbed.

this fixes the fatal error locally, and shouldn't cause any conflict on the production site.

though i'm not sure what causes the error locally and not on the production site...