Commit Graph

485 Commits

Author SHA1 Message Date
Bobby Wibowo
917afdf7a8
Updated uploadController.js
Fixed a bug where error messages related to multer would not be displayed properly (it would instead print "undefined").
2018-07-12 13:34:22 +07:00
Bobby Wibowo
616da886f7
Updated README.md 2018-06-17 07:44:22 +07:00
Bobby Wibowo
dfb50da223
Merge branch 'master' into safe.fiery.me 2018-06-16 05:46:21 +07:00
Kana
82e8e7167b
Merge pull request #130 from VVLNT/original
because why not
2018-06-15 17:22:56 -03:00
VVLNT
5ca83af4a4 because why not 2018-06-15 22:11:54 +02:00
Bobby Wibowo
0b6df9efe4
Merged changes from master
Summary:
* Added 3 new sites to README.md.
* Added some new file extensions to filter.
* Some additions to nginx sample conf files.

Changes such as delete buttons and whatnots for the dashboard were not added.
2018-06-06 08:51:53 +07:00
Bobby Wibowo
9396a9ab49
Updated uploadController.js
Better snekfetch's error handling, probably.
2018-06-06 00:40:33 +07:00
Bobby Wibowo
57834dd362
Updated uploadController.js
Added DuckDuckGo's proxy support for "Upload by URLs". Make sure you add the new option in config.sample.js into your config.js.

This may be considered a hack and not supported by DuckDuckGo, so USE AT YOUR OWN RISK.

Credits to Proxy#1337.
2018-06-06 00:16:41 +07:00
Kana
c46f5d9b31
Merge pull request #128 from cmyui/patch-1
anotha one
2018-06-03 23:29:49 -03:00
Josh
67d7bf18b3
anotha one 2018-06-03 21:39:39 -04:00
Kana
210967396e
Merge pull request #125 from ImUrX/patch-1
Add new site
2018-06-03 11:17:31 -03:00
Uriel
1bc9c1ed7f
removed wip 2018-06-01 09:01:23 -03:00
Uriel
953981f48d
Update README.md 2018-05-31 14:48:24 -03:00
Kana
cbe73ed1ec
Merge pull request #122 from Shumatsu/extensions
File extension bans
2018-05-21 18:23:58 -03:00
Shumatsu
a9ac6b1574
Adjusting to recommendations 2018-05-21 23:22:54 +02:00
Shumatsu
df6d5459e0
File extension bans
`.nt` - turns out there's more Windows batch file extensions.
`.psm1` - PowerScript extension.
`.bash`, `.bsh`, `.csh`, `.bash_profile`, `.bashrc`, `.profile` - apparently those are valid bash script extensions.
`.reg` - overwrites Windows registry keys upon execution.
2018-05-21 23:13:39 +02:00
Kana
41fd4fb81d
Merge pull request #118 from NadyaNayme/no-thumb-deletion
Fix: File Deletion for No Thumbnail in Album View
2018-05-21 04:51:47 -03:00
Kana
3bb212cfda
Merge pull request #117 from Kosemii/patch-2
Fixed an issue with dashboard
2018-05-21 04:51:26 -03:00
Nadya
55e64b1f36 Fix: File Deletion for No Thumbnail in Album View
If a file did not have a thumbnail the delete button would not render.
2018-05-20 15:12:33 -07:00
Kosemii
f28fcf4388
Fixed an issue with dashboard
Fixed an issue cutting off delete button in dashboard
2018-05-20 23:04:33 +01:00
Kana
0994355c7e
Merge pull request #113 from Kosemii/patch-1
Added site
2018-05-20 18:39:47 -03:00
Kana
7655d87066
Merge pull request #116 from NadyaNayme/fix-typo
Fixes typo of charset_Type
2018-05-20 18:31:46 -03:00
Nadya
18b5d8eed9 Fixes typo of charset_Type
unknown directive charset_type, because the directive is charset_types
2018-05-20 14:25:15 -07:00
Kosemii
e0911494e6
Added site 2018-05-19 12:17:37 +01:00
Kana
0f66d74683
Merge pull request #111 from NadyaNayme/better-nginx-settings
Small nginx.config improvements
2018-05-19 05:08:25 -03:00
Nadya
30e460b7f8 Improve nginx defaults
Don't send nginx version in headers and serve all text/* as utf-8
2018-05-19 00:57:19 -07:00
Kana
e07e87e061
Merge pull request #107 from NadyaNayme/Album-Delete
Album View File Deletion
2018-05-13 00:01:49 -03:00
Nadya
ba6b3764dc
Fix typo 2018-05-12 19:25:19 -07:00
Nadya
8758ccac82
Merge pull request #2 from NadyaNayme/Album-Delete-Styles
Styles for Album View Delete
2018-05-12 19:20:14 -07:00
Nadya
ef4e7755ae
Styles for Album View Delete 2018-05-12 19:19:38 -07:00
Nadya
92efc7bf17
Add Delete to Album View
QOL change.
2018-05-12 19:17:21 -07:00
Bobby Wibowo
369b1137a7
Updates
* Some structure updates to the homepage and the No-JS uploader form. Making them both somewhat look better, especially in terms of spacing.

* Upload URLs form will now show an error alert when there the form is empty or only filled with whitespaces.

* Upload URLs form will now automatically remove empty lines or lines that consist of only whitespaces when the upload button is pressed.
2018-05-13 05:13:26 +07:00
Bobby Wibowo
0cf8ff58d0
Updated uploadController.js 2018-05-13 02:16:04 +07:00
Bobby Wibowo
c4eed6e478
Updates
* Added globals.v3 to _globals.njk, which will be used for CSS/JS files of libs (bulma, lazyload, etc.). globals.v1 will now only be used for lolisafe's JS and CSS files.
Since CSS/JS files of libs receive much less updates than lolisafe's (mainly since I push updates a lot), this will decrease the amount of files that users need to re-fetch on every updates.

* Added public/js/album.js which will be used by album.njk (albums public link). I'm going to disable inline scripts in safe.fiery.me.

* Better FAQ. Some points will now dynamically changes depending on the settings you have in your config.js. It's not perfect but certainly much better than before.
2018-05-12 23:34:19 +07:00
Bobby Wibowo
7f23734d67
Updates
* Faster upload response. Back-end will no longer wait for album timestamps to be updated before sending out response.

* Added a simple thumbnail generation script at scripts/thumbs.js. You can use this to generate thumbnails for existing files before enabling the option in config.js.

* Various other code improvements.
2018-05-12 21:01:14 +07:00
Bobby Wibowo
4d634196c5
Updated home.js
* Cache selected album the exact moment "Upload URLs" button is pressed, so that any in progress requests will not have its album id altered.

* All URLs will now be displayed in the uploads list (the thing in between upload buttons and footer links) the moment "Upload URLs" button is pressed. Previously it would only show the URLs one by one after each finished request.
Brief video: https://i.fiery.me/AByv.mp4.
2018-05-11 22:10:49 +07:00
Bobby Wibowo
933fcb8612
Updated screenshot in README again
I can't remember whether I used to use a logged in screenshot or not...
2018-05-11 22:02:03 +07:00
Bobby Wibowo
a3dabb33b1
Updated home.css
Changing the blue color of active tab to match the color scheme.
2018-05-11 21:46:39 +07:00
Bobby Wibowo
33735018d5
Updated README.md 2018-05-11 21:40:29 +07:00
Bobby Wibowo
bd722129de
Updates, now supports uploading by URLs!
* Added upload by URLs. It has its own max size (config.uploads.urlMaxSize), make sure your config matches config.sample.js.
Here's a brief video showing it in action: https://i.fiery.me/CUhQ.mp4.

* /api/upload now supports uploading by URLs. Devs will only need to POST a JSON request containing a key named "urls", which is an array of the urls to upload.

* Added file extension filter to /api/upload/finishchunks.

* Added proper total chunks size check to /api/upload/finishchunks.

* Various code improvements.
2018-05-11 21:34:13 +07:00
Bobby Wibowo
479db54cd3
Updates (experimental)
* Possible performance improvement. Some bulk db queries will now be executed in a single query instead of spawning multiple async task for each query. This is sorta experimental though, use it at your own risk (though I'll use it right away at safe.fiery.me).

* It's now possible for root user to add files to other users' albums through the API route. I don't plan on allowing root user to list other users' album list from the dashboard, I just thought that there'd be no harm in extending the API a little bit.

* Kinda better error logging for uncaught exception and unhandled rejection. Their stack trace should be logged now.
2018-05-11 00:25:52 +07:00
Bobby Wibowo
a4f9a0f8df
Updated unavailable.png
Removed pattern thingy.
2018-05-10 22:12:16 +07:00
Bobby Wibowo
c952e3e8ce
Updated utilsController.js
Possibly better Cloudflare error handling.
2018-05-09 17:18:16 +07:00
Bobby Wibowo
fbd38a8bdd
Updated utilsController.js
Forgot to symlink 'unavailable thumb' placeholder for failed video thumbs.
2018-05-09 17:07:23 +07:00
Bobby Wibowo
f043f65ca1
Updates
* Added Cloudflare purge cache support. Check configuration sample at config.sample.js.
When it's enabled, whenever files are being deleted, it will send a POST request to Cloudflare's API to purge cache of the deleted files.
This adds a new dependency called "snekfetch". It's lightweight though.

* uploadsController.delete() will now wrap uploadsController.bulkDelete() instead.
2018-05-09 16:53:27 +07:00
Bobby Wibowo
7991a63315
Updates (please update your config.js)
NOTICE: Please update your config.js. Use config.sample.js as the template.
There were a couple of renames and restructures.

* Album zipper API route will now internally save its state when it's generating zip files, and any subsequent requests will silently be "postponed" until the first spawned task is finished. This will guarantee that there are no multiple zipping tasks for the same album. The method may seem a bit hackish though.

* All instances of console.log(error) were replaced with console.error(error). This will guarantee that any error goes to stderr instead of stdout.

* Deleting file by names will now properly remove successful files from the textarea. There was a logic flaw.

* Failure to generate thumbnails will no longer print the full stack, but instead only the error message. It will also then symlink a template image from /public/images/unavailable.png (it's only a simple image that says that it failed to generate thumbnail).
This haven't been tested in Windows machines, but it'll probably work fine.
I thought of adding a new column to files table which will store information whether the thumbnail generation is sucessful or not, but oh well, I'll go with this method for now.
2018-05-09 15:41:30 +07:00
Bobby Wibowo
d86dfc9b0e
Updated README.md 2018-05-06 21:26:16 +07:00
Bobby Wibowo
7eccdbde63
Updated README.md 2018-05-06 21:25:15 +07:00
Bobby Wibowo
9e069f5a9a
Updates
* Added "create new album" button at homepage uploader. Due to this, albums list will always be shown even when you don't have any albums (and of course the list will be empty).
Preview: https://i.fiery.me/ITQ5.mp4 (ignore the fact that the prompt says "Edit album", it's been fixed before this commit goes live)

* Refactored various bits of the codes to use async/await instead of Promise.then. This will obviously cause the browser's requirement to raise but hell, it's the modern browsers age.

* Various other code improvements.
2018-05-06 21:14:57 +07:00
Bobby Wibowo
08410faa9a
Updates (breaking changes!)
* Updated API route: /upload/bulkdelete.
It now accepts an additional property named "field". In it you can now enter either "id" or "name", which will set whether it will bulk delete by ids or names respectively. It also no longer accepts property named "ids", instead it has to be named "values" (which of course is an array of either ids or names). So yeah, now the API route can be used to bulk delete by ids and names.
In the future this will be expanded to bulk deleting files by username (only accessible by root of course).

* Added a form to bulk delete files by names for the hardcore user, like me (https://i.fiery.me/AHph.png).

* Some design update. Mainly forms restructuring aimed at tight screens.

* Changing file name length, requesting new token and setting new password will no longer reload the dashboard page on success. Instead it will simply silently reload the form.

* utils.bulkDeleteFilesByIds() replaced by utils.bulkDeleteFiles() which now can either by ids or names. This will be the one that will eventually be extended for deleting by username.

* Various other code improvements.
2018-05-06 02:44:58 +07:00