The check.sh script was broken in #5166, this fixes it * Related to #5297 * [x] I have followed the instructions in the PR template --------- Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>