Pre-receive hook displaying unwanted content

GitLab version - 9.3.6

Recently I added the pre-receive hook for blocking the binary file pushing. I can get the expected out in my gitlab testing server machine (below image)

I added the same hook file on the live server machine. But I got another extra line (below) in displaying the message.

Actually, my hook is working properly. But there is an extra line displaying in the message. I am sure, there no extra printing statement on my hook file.

My commit message is

remote: hooks/pre-receive:3: warning: Insecure world writable dir /opt/gitlab/embedded/libexec in PATH, mode 040777        

remote: Hello there! We have restricted the binary files (.exe, .dll, .zip, .7z, .deb, .cab, .gz, .pkg, .iso) that are pushed into GitLab.        
remote: Your changes contain following file(s) from origin commit c7a151fb to a4e7c31c. Kindly remove the following file(s) and try again.        
remote:     NewTest.dll        

How can I remove the line hooks/pre-receive:3: warning: Insecure world writable dir /opt/gitlab/embedded/libexec in PATH, mode 040777 from that message line?

I get rid of this issue by using sudo chmod go-w /opt/gitlab, sudo chmod go-w /opt/gitlab/embedded/bin and sudo chmod go-w /opt/gitlab/embedded