Fixes issues with exports.

See commits to see what was changed.