| Age | Commit message (Collapse) | Author |
|
ShareX has moved its source code repository to GitHub. Google Code is
also shutting down, so update and point the URL to the GitHub
repository.
While we are here, update and sanitize the ShareX settings we need to
use. Also update the copyright year in header.
Reported-by: Jaex
Suggested-by: Jaex
|
|
We are ready to release Pomf 2.0.0. Patches will follow semantic
versioning, so th next 2.0 branch release will be 2.0.1. The next
feature release will be the 2.1 branch with release 2.1.0.
OK ewhal@
|
|
New code has been added to Response.class.php this year in commit
b94ac9a. Update LICENSE and Response.class.php copyright header with
year 2016.
We can't do this for every file in the project repository unless they
are actually changed, due to the way our copyright legislation works. We
also can't remove the mention of 2015, because most of the code was
initially published in 2015 and so remains copyrighted since that year.
|
|
Clean up a lot of the cruft in Response class.
Gyazo is deprecated and falls back to 'text' for similar functionality,
reducing code duplication. It will be removed in a future release.
CSV gets a text/csv Content-Type. CSV linebreaks are also now CRLF, and
values are wrapped in quotes.
The default error is now a JSON response instead of a generic 400 Bad
Request in plaintext.
output=json is now explicit and no longer undefined behavior.
|
|
The gyazo response would return an empty response, because the construct
didn't actually fallthrough to text properly. Force gyazo's response
type to be 'text' to fix the issue.
Accordingly, the 'gyazo' cases for send() and error() now become dead
code. Remove them.
OK ewhal@
|
|
Add myself to package.json contributors. I have a significant amount of
code and effort dedicated to this project, so I can be contacted for
questions.
OK ewhal@
|
|
Lint our spaghetti JavaScript code to be at least slightly more
readable. Configuration used is ESLint 1.7.x and airbnb/legacy.
It's been so long I cannot remember every change that was done, but long
story short: all the ESLint errors are now gone, at least at the date of
last commit.
moep contributed some ideas for patches: some were implemented, some
were discarded as the time and patience for merging this ran out. Thus,
there are still ESLint warnings about anonymous functions.
I don't feel like spending much more time on this. The future Pomf 2.1
development branch will replace the JavaScript code in its entirety,
courtesy of luminarys@.
Suggested-by: moep
Tested-by: Eliot Whalan <ewhal@pantsu.cat>
OK ewhal@, maybe a vague OK from luminarys@ a long time ago
|
|
|
|
Reword the "no Git issue tracking" policy in contributing section.
Previously the contributing section in README.md would say we don't use
git.pantsu.cat's issue tracker to track issues. That Git service
repository's issues have been disabled today, so we might as well say we
don't use any Git service issue tracking. Unofficial mirrors like the
one on notabug.org may still have issue tracking, which I believe we
have no control over.
This commit also clarifies that we do it for ethical and technical
objections. (In short, it's because the Git service is centralized and a
walled garden.) For more information, see
wubthecaptain/deathwatch-pomf@fc86cbf for information why.
|
|
Peter Lejeck's (peter.lejeck@) only commit in the file is a507748, which
is pretty much just the HTML layout in the file. I have changed that, a
lot.
Eric Johansson's (neku@) commits in the file covered the text itself.
This too has been replaced in commit 7d61e04, which rewrote all the
text in the page.
In other words, these two authors no longer have any meaningful content
in the file to be attributed. Much of the copyright goes to the
Pantsu.cat developers - which covers myself too.
OK luminarys@, "no complaints"
|
|
Fixup to previous commit 120627d. Fixes Grunt build failure.
Gladly, I am working on replacing Grunt with Makefile for 2.1.0 or 3.0.0
release so that these mistakes should happen less frequently.
|
|
Catalan translation was removed in commit 566611c. However, the commit
was incomplete and forgot to remove the swig build task from Grunt.
We can safely remove these Catalan pages from Grunt swig build. They no
longer exist and this is dead code.
OK luminarys@
|
|
Previous commit c950e85 came with a workaround to resolve a TypeError in
EventEmitter.prototype.emit for-loop. That workaround sacrificed some
readability for bug fixing due to technical debt.
bursey came up with a better solution on IRC which seems to work and
improves readability. Something needs to emit an event that wasn't bound
with "on", thus the event was not in the _events object.
Airbnb ES5 style guide requires to have all variables at top, so we
leave the len variable undefined at the top to be defined later. After
the _events check, we define len to avoid the TypeError issue while
conforming to Airbnb ES5 style guide and improving readability.
This commit also adds comments to document the function.
Suggested-by: bursey (#/g/partyvan @ Partyvan IRC)
|
|
this._events[evt].length would run into JavaScript scope issues in
EventEmitter.prototype.emit function for-loop.
This is an attempt to work around the issue to resolve an innocent
looking TypeError. The code seems to work without this patch, but I
can't spot if this is some dead code or know what to do with it. Due to
technical debt, some sacrifice had to be made in readability for fixing
this bug.
This bug was introduced in commit 575b78b.
For future improvement, this function and other functions in the file
should be refactored or replaced with a more efficient implementation.
|
|
Very short identifier names usually make the code harder to read and
potentially less maintainable.
Fixes two ESLint id-length errors using airbnb/legacy config.
Suggested-by: avail <avail@pomf.se>
|
|
- Rephrase check_script.swig JavaScript warning
- Remove check_script URL dependency to no.pantsu.cat
OK ewhal@
|
|
check_script.swig would hardlink to no.pantsu.cat domain for the purpose
of Catalan translations as part of a hack. Catalan translations were
removed in commit 566611c, so we can link to the nojs.html page directly
(built at compile time).
This assures that all sites using this project's code will have less to
tweak to make this project work on their site.
|
|
Clarify that the site requires JavaScript to function and what the user
should do. Telling the users only "Javascript free version" is confusing
at best, and we can do better.
For future improvement, the JavaScript-free version may be integrated on
the same page as the JavaScript uploader.
|
|
When a local variable shares the same name with a variable in its scope,
it can cause confusion to the reader and make it impossible to access
the global variable.
Disallow shadowing. Fixes ESLint no-shadow errors using airbnb/legacy
config.
Suggested-by: marc <mharnos@gmail.com>
|
|
Quoting ESLint:
> Variables that are declared and not used anywhere in the code are most
> likely an error due to incomplete refactoring. Such variables take up
> space in the code and can lead to confusion by readers.
This commit removes them. Fixes ESLint no-unused-vars errors using
airbnb/legacy config.
Suggested-by: marc <mharnos@gmail.com>
|
|
(Partially reverts commit e0bb4e0.)
Actually fix generate_name() COUNT query this time. It still had an
imaginary table "pomf" from e0bb4e0. Change it to "files" like in the
schema.
For code consistency, :filename is reverted back to :name as it was
before commit e0bb4e0. That commit is bogus and doesn't fix the issue
due to skipping the code review process.
The problem with this COUNT query in first place was that it checked
imaginary columns (name) from an imaginary table (pomf) in the database.
This led to the "same filename" check not working at all, and the other
code only relying on checking the same hash (currently SHA-1) for
returning the filename before generate_name().
By luck, generated filenames could collide and another file of the same
generated filename would be returned, discarding the new upload.
I discovered this bug about a month ago myself, but back then there was
no reliable way to reproduce it and no good description of the bug.
This bug was introduced in commit 5b77a4e.
Reported-by: Vhum Vhum <vhumvhum1@gmail.com>
Suggested-by: Luminarys <luminarys@fuwa.se>
OK ewhal@, luminarys@
|
|
database
|
|
Hidden <input> values did not work as I expected for POST requests. In
GET requests, the hidden values are added as query parameters to the
URL. For POST requests, the hidden inputs are simply more form-data to
upload in the POST request (another "file").
Because of this, the HTML output parameter is never passed to upload.php
and so it returns the default response instead (JSON). The goal is to
use the HTML response.
This reverts commit d6dc103c7229cb0e2e177ce0dfc0cfb528025ca9, where the
bug was introduced.
OK ewhal@
|
|
Bump grunt-contrib-copy ^0.8.1 -> ^0.8.2. While this is not entirely
necessary, do it anyway to keep our package.json up to date with latest
releases.
Bump grunt-contrib-uglify ^0.9.2 -> ^0.10.0. Updates UglifyJS dependency
from ^2.4.24 -> ^2.5. May result in better, smaller or less buggy
minified JavaScript, although this has not been tested.
If everything goes well, this commit doesn't change anything. Carets
will automatically update to latest major version. This commit just
means we are showing to drop support for some older versions, despite
package.json really instructing to download a newer release.
OK ewhal@
|
|
Clean up CSS. Removes an off-screen content hack and removes
unnecessary, dead style rules.
POCKY~ rules have never seen light in the source code, not in core nor
moe panel.
CSS border-box vendor prefixes are long since unnecessary and border-box
is supported natively by browsers.
OK ewhal@
|
|
Add .mailmap, which is a git-shortlog(1) feature. Maps author names with
different names/email addresses under one name.
OK ewhal@
|
|
The message and the results for why the law enforcement must be
contacted may be unclear to some. Add "they may contact us if
appropriate" to clarify the message and uphold the legal spirit, for the
lack of better words.
|
|
As seen on the ShareX project's home page, the correct spelling of the
name is with an uppercase `X`. On the tools page, it is incorrectly an
lowercase `x` (Sharex). This corrects it.
|
|
The pantsucat/pomfsecure repository has been dead for a very long time.
It is giving a "404 Not Found" error. Fix the download link to a working
Git repository.
|
|
- Revert project name change made in commit 0ab45bf3 back from Pantsu
back to Pomf.
- Change package version to 2.0.0-dev (one time early version change
exception).
- Change description's initial character to camelcase.
|
|
ewhal@ didn't understand how changing the maximum file size works, so he
edited the JavaScript code directly to set the default to his desired
120MiB.
For all clones, this may not be viable and it's not a sane default in my
opinion. This doesn't change the fact that the maximum file size remains
to be what it's configured in the configuration (Gruntfile.js).
This bug was introduced in commit ec0154b, and potentially others.
Vague OK from ewhal@ many weeks ago.
|
|
Validate CSV responses by wrapping them in double quotes and using CRLF
linebreaks.
CRLF linebreaks are used to conform RFC 4180. Double quotes can be
useful to avoid subtle bugs and validation errors.
This code is ugly. For future improvement, something like arrays could
be used or dropping support for CSV API completely.
Vague OKs from ewhal@, luminarys@
|
|
Problems with placing #upload-input off-screen is that keyboard
navigation (tab) will gain focus of the upload buttons twice.
Hiding the other upload button (the <input> element) off-screen makes no
sense because no explanation is given. Hide it with `display: none;`.
Considering screen reader users, the <button> element (with a future
<label> element) should hopefully convey enough information about it's
purpose. `tabindex="-1"` would be an alternative, but would require
placing content off-screen.
|
|
border-box has been supported natively in web browsers since Chromium
10, Firefox 29.0, Internet Explorer 8, Opera 7, Safari (WebKit) 5.1. IE
never also had a vendor prefix.
As a guideline, as of today Firefox ESR (extended support release) is on
version 38.3.0, so native support has been available for a long while.
These vendor prefixes are no longer needed. This commit removes them.
For future improvement, matching this rule against wildcard `*` should
be re-considered and moved to body or some other rule to avoid expensive
CSS calculations.
|
|
Pomf core nor moe panel have never used these POCKY~ style rules. They
have no reason to exist. Remove them for cleanup.
Reported-by: Luminarys <luminarys@fuwa.se>
|
|
There are commented style rules in the CSS that do not appear to have
been used in a long time, and have no reason to exist. Remove them for
cleanup.
|
|
Update the FAQ to be semantically more correct, easier to read and
pretty.
A lot of here applies to Pantsu.cat specifically. For future
improvement, a generic FAQ may be created and this FAQ split into an
extension repository (pomf-pages-pantsucat or similar).
OK ewhal@
|
|
Although alchimist has not yet merged any commits to master as of this
commit, it is anticipated to happen eventually after he's done working
with his branches. Regardless, adding this makes sure git-shortlog(1)
will display the up-to-date email address.
|
|
Eliot has also contributed three commits with his name using
contact@pantsu.cat. The match on pantsucat name is too specific.
This groups those three commits to Eliot Whalan <ewahl@pantsu.cat>.
|
|
From git-shortlog(1) man page:
> The .mailmap feature is used to coalesce together commits by the same
> person in the shortlog, where their name and/or email address was
> spelled differently.
|
|
A "valid notice" for copyright takedown is questionable and doesn't tell
much of a clue what needs to be in a takedown notice. Change it to
specify Copyright Act 1968 (Australia), which is the current copyright
legislation in Australia.
For future improvement, a copyright takedown page could be created with
more detailed instructions what needs to be included in a copyright
takedown notice.
|
|
nav.swig includes were inconsistently at either bottom of the page or
inside the jumbotron. For FAQ, the navigation was also nested
incorrectly inside the <article> element, which means the navigation
incorrectly assumed to be in-article navigation (table of contents).
The intention is to have these nav.swig (site-wide navigation) includes
outside of <article> scope. Future improvement is desired to have all
pages like other.swig and tools.swig to have <article> elements.
|
|
The <article> element is an element introduced in HTML5 for semantic
sectioning.
faq.swig is missing this semantic element, so this commit adds it.
It doesn't seem appropriate to use <article> in layout.swig, because
it's used for every page, also ones that are not articles.
Reference: http://www.w3.org/TR/html5/sections.html#the-article-element
|
|
The previous paragraph is misleading. On takedown notice, the intention
is not to disable access to files the complainer has uploaded. This
fixes the paragraph to say the intention is to disable access to
infringing content.
|
|
Me and antonizoon have decided to create a new central channel for
Pomf.se clone discussion. This leaves #/g/hostingtalk dedicated to its
intended purpose, general server hosting discussion.
The channel name #pomfret comes from ArchiveTeam's EFnet channel of the
same name, which was used to rescue Pomf.se's files. The channel on
EFnet is without OPs these days. antonizoon also suggested lots of
imageboard/chan channels are also on Rizon, so Rizon was chosen for the
channel as a good fit. Rizon also houses the #bibanon channel, which is
the official channel for Bibliotheca Anonoma.
OK ewhal@
|
|
The banner in FAQ seems out of place and doesn't really belong to the
page. This commit removes the banners from faq.swig. The banners are
still kept on the index page.
|
|
The previous FAQ is difficult to read and doesn't actually answer to
common questions. It also lacks semantics.
Because the previous FAQ had reached a point of being next to useless
and unfixable with minor edits, it had to be rewritten.
This commit addresses the most commonly asked questions. It uses HTML5
headings for addresssing each question for proper document outline. For
future improvement, more may be added as necessary.
|
|
FAQ itself as a word as unsemantic to screen readers and not accessible.
Adding an <abbr> element improves accessibility and makes screen readers
read the title correctly.
|
|
Peter didn't actually write this piece of Swig template, and there's an
insignificant amount of templating code that could have been written by
him. We can remove him from this template's authors.
|
|
The link to real world example at Pantsu.cat is not semantically a
feature, but its own demonstration. Adding a subheader for the example
increases semantics further, and makes it easier to find.
|