backported core changes into mopub library