Do the upload in the parent addon script rather than from content

You might find this PR more to your liking.