Skip to content

Instantly share code, notes, and snippets.

View tassaron's full-sized avatar

Brianna Rainey tassaron

View GitHub Profile
@tassaron
tassaron / increase_mastodon_char_limit_to_5000.patch
Last active June 4, 2023 21:14
Increase Mastodon v3.5.3 character limit: git apply --ignore-space-change --ignore-whitespace increase_mastodon_char_limit_to_5000.patch
diff --git a/app/javascript/mastodon/features/compose/components/compose_form.js b/app/javascript/mastodon/features/compose/components/compose_form.js
index 4620d1c43..bbc4b7edc 100644
--- a/app/javascript/mastodon/features/compose/components/compose_form.js
+++ b/app/javascript/mastodon/features/compose/components/compose_form.js
@@ -90,7 +90,7 @@ class ComposeForm extends ImmutablePureComponent {
const fulltext = this.getFulltextForCharacterCounting();
const isOnlyWhitespace = fulltext.length !== 0 && fulltext.trim().length === 0;
- return !(isSubmitting || isUploading || isChangingUpload || length(fulltext) > 500 || (isOnlyWhitespace && !anyMedia));
+ return !(isSubmitting || isUploading || isChangingUpload || length(fulltext) > 5000 || (isOnlyWhitespace && !anyMedia));
//Referred link https://www.lunchbadger.com/tracking-the-performance-of-express-js-routes-and-middleware/
var express = require('express')
var uuid = require('uuid')
const bodyParser = require('body-parser');
const {
EventEmitter
} = require('events');
const profiles = new EventEmitter();