Interesting. Notably, they also call themselves "open source" in the "About" of the repository. I'm not aware of any critical extensions which are closed-source. The change you've highlighted was made 4 months ago under a commit that gives no explanation: https://github.com/mattermost/mattermost/pull/31247/files , and the discussion there is private.
This mainly seems to relate to metrics and fuzzy search, though it's possible more will move here in the future (it looks like this is a relatively recent development). Until recently they also had experimental support for Bleve full-text search (now seemingly deprecated), but the elasticsearch enterprise feature seems to be the replacement (otherwise they use postgres's ILIKE for built-in text search)
So, all told, Mattermost was open source, and may be moving to open core. Which means now is probably the best time to create a community-maintained fork. The team edition, and almost all features, are currently still open source.
It sounds like the enterprise release is not open source? When someone above says "The whole thing is AGPLv3," I'm not sure everyone is talking about the same "whole thing"?
Notably, they do have some "source-available" code that goes into the enterprise release, at https://github.com/mattermost/mattermost/tree/master/server/...
This mainly seems to relate to metrics and fuzzy search, though it's possible more will move here in the future (it looks like this is a relatively recent development). Until recently they also had experimental support for Bleve full-text search (now seemingly deprecated), but the elasticsearch enterprise feature seems to be the replacement (otherwise they use postgres's ILIKE for built-in text search)
So, all told, Mattermost was open source, and may be moving to open core. Which means now is probably the best time to create a community-maintained fork. The team edition, and almost all features, are currently still open source.