If you use git
to manage you Moodle install (https://docs.moodle.org/310/en/Git_for_Administrators
), and if the change is sufficiently self-contained, then back-porting can be easy.
First you need to fetch all the latest version history: I am going to assume here that you just cloned the Moodle repo, so that is 'origin'. (If you don't know what that last sentence means, then the assumption is probably safe
git fetch origin
The output for that should show you that a bunch of branches have been updated, including origin/MOODLE_311_STABLE
Then you need to find the commits that implement this feature:
git log --grep MDL-68597
Then, you need to apply those changes to your Moodle code, which requires knowing that git log shows them in reverse order. So, one at a time, execute
git cherry-pick 9b7439c3a8c17e9fe363da6c9784f0752dffa2f5
git cherry-pick 48e0b24587518064d5d47d5ca370e00a8d37e158
git cherry-pick 8d7b3b3fe72532c74a284d6e3dba3e9d444a8406
git cherry-pick 8306fc3f3e28936c87443fae6435efb0e35be474
If any of those give a merge conflict, then it is no simple. (I suspect that there may be merge conflicts in the qusetion/type/essay/version.php file, but hopefully only there.
Also, once you have done this, upgrading to the next stable release (e.g. 3.10.2) may not go smoothly. This is the biggest risk in doing this.
I think git cherry-pick is safer than copying the whole plugin folder from a different release. However, the key folder here is not mod/quiz, but question/type/essay.
Whatever you do, test it on a copy of your site before you do it for real.