My understanding is that Chilul Hashem - desecrating G-d's name can be caused when Gentiles have a negative opinion about Jews from observing wrong behavior, even if the behavior may be halachically permissible, but it causes them to have a negative impression.
Let's say that you have a Gentile co-worker in your office who is a "Shabbos Goy" for a Jewish family. It's summertime in the NY area and candle lighting is about 8:10. The Jewish family starts Shabbat early at 7 PM. As the Gentile is about to leave at 6:45 to go to her job, she sees that you are still at work, and says, "Aren't you supposed to go home, now? Shabbes is at 7!" You say, "Actually, Shabbes starts at 8:10, and I have time to go home. Your employer is starting Shabbes earlier at 7."
The Gentile gives you a look, and says, "Don't tell me that! My boss knows when Shabbes starts and he wants me to be there on time for his Shabbes! You're going to be late!"
So, now you gave her the impression that maybe it's OK for Jews to desecrate Shabbes based on whatever they feel like doing, and you gave her an "excuse".
Should you have just left early to avoid the problem, or can you ignore what she may think, as you know she is misinformed? Let's say you have an important work deadline to meet and you need to stay there a bit longer?