Issues with connection to Player.Chatted

Trying to create a chat command, connection to .Chatted doesn’t respond.

0518924d909623f07b775a35b2d29f08

At the same time, default character Animate script connects to Chatted and everything works in there.

b3cd1ed0bb222d60a21187a30217989b

Here is code of that default connection:

Here is my code:

game:GetService("Players").LocalPlayer.Chatted:connect(function(msg)
    print(msg)
end)