Improve gitlab:check. Fix 2776

Fixes #2776