The post_uploads table has been deprecated. This commit updates the 'Top 50 Largest Uploads' query to use the new upload_references table instead.
This commit updates the plugin to the latest guidelines, as shown in discourse-plugin-skeleton, which involves moving a lot of the code to dedicated files, use proper namespaces, use the autoloader as much as possible, etc.