I assumed that you used a task because you believed that in putinserver the player name is not available yet. In this context it doesn't matter much, both are correct, but the task seems to be useless, just use the second way since you will get the same result.