Submodules update checking out on commit instead of specific branch

I have a submodule configured just like that:

[submodule "submodule-name"]
	path = submodule-path
	url = git@gitlab.com:submodule-url
	branch = master

Every time I run git submodule update --recursive --remote, my submodule is checked out on a commit instead of my master branch, as specified in my .gitmodules file.

My gitlab version is 10.8.5-ee (8f03e3e9).

Has anybody ever had this problem?

Edited Jan 31, 2019 by Gabriel Oliva
Assignee Loading
Time tracking Loading