10 Commits

Author SHA1 Message Date
Le Philousophe 7b0a2033de WEB: Gracefully handle cases when there are no extension in files 2025-08-24 12:32:47 +02:00
Le Philousophe 710b95a5f4 WEB: Better error handling
When PHP functions fail they often return false instead of the expected
object type.
CHeck for this value and fail properly.
2025-08-24 12:32:47 +02:00
Le Philousophe cc9fa80181 WEB: Add typing 2025-08-24 12:32:47 +02:00
Le Philousophe d7c3bd0528 WEB: Various small fixes
These are either cosmetic or spotted by PHPStan
2025-08-24 12:32:47 +02:00
Le Philousophe 7cd3ff2331 WEB: Various PHPStan fixes
These fixes are only for correctness.
2024-09-14 13:14:49 +02:00
Thunderforge f25dbcc8fa WEB: Removing unused imports 2023-05-24 18:42:56 -05:00
Thunderforge c8ea57598f WEB: Displaying file sizes as MiB etc (#250)
This is a result of the discussion from PR #230 where the consensus was that the consistent and accurate, if inconvenient, units (KiB, MiB, GiB) were preferred over the ambiguous units (kB, MB, GB).
2022-06-14 17:23:37 -05:00
Thunderforge 87c4ed02ba WEB: Return .tar.lz instead of .lz 2022-01-11 22:47:36 -06:00
Thunderforge f90e1e3406 WEB: Changing getLastModified($path) to return as ISO 8601 date (#194)
We don't need second precision when showing last updated, so reducing from datetime to date. Changing to ISO 8601 has the added benefit of reducing visual complexity and also preventing the need to translate the spelled out dates.
2022-01-10 18:54:57 -06:00
Thunderforge 453e74263b WEB: Adding file size and extension to recommended downloads (#191)
* WEB: Refactor reading files into FileUtils

Refactoring code in `include/Objects/File` into `FileUtils`. This not only makes the code much cleaner, but also allows it to be used in other places of the app, such as the `DownloadsModel`.

* WEB: Adding file size and extension to recommended downloads
2022-01-10 15:39:01 -06:00