make custom pdf optional