Fix issues with PHP notices and sanitizing in the media credit plugin