7 Dear friends, I am not writing you a new command but an old one, which you have had since the beginning. This old command is the message you have heard. 8 Yet I am writing you a new command: its truth is seen in him and you, because the darkness is passing and the true light is already shining.9 Anyone who claims to be in the light but hates his brother is still in the darkness. 10 Whoever loves his brother lives in the light, and there is nothing in him to make him stumble. 11 But whoever hates his brother is in the darkness and walks around in the darkness; he does not know where he is going, because the darkness has blinded him.
So, John says he’s writing a new command, but he doesn't say it outright here. What is it? Love one another. He actually does reveal this in his gospel record where he quotes Jesus: “A new command I give you: Love one another. As I have loved you, so you must love one another.”
Notice how many times the word light appears. Read verse 10 again and think about the marvelous "consequences" of loving your brother (neighbor): there’s nothing to make you mess up if you love one another.