kensanata / bitlbee-mastodon

A Mastodon plugin for Bitlbee
https://alexschroeder.ch/software/Bitlbee_Mastodon
GNU General Public License v2.0
30 stars 7 forks source link

hardcodes default maximum tweet length #39

Open velartrill opened 4 years ago

velartrill commented 4 years ago

currently, bitlbee-mastodon simply assumes the maximum length of a tweet is 500 chars, and provides a setting to allow the user to set the maximum length to the correct value for their server. however, pleroma and glitchsoc (at the very least) provide a means to query an instance for its maximum character length - we should use this instead when it's available. this can be retrieved from the max_toot_chars field of the /api/v1/instance endpoint; if not present, it can be reasonably assumed that the user is accessing a vanilla mastodon server. i recommend that we query the API and check for the field during account creation, and preserve current behavior if the field is not found.

kensanata commented 4 years ago

Sounds good to me!