okay after some advice I think I got it to work by doing the following:
Open shortcode.php in the lib folder
change the following line of code:
$prev_match = $prev_matches[0];
to
$prev_match = end($prev_matches);
I’ve only tested it a few times and it seems to be working, as always make a backup of your files before testing this…