Just because the package was delivered doesn't make it "safe"
Now, what did you have inside? If it was GHB or Kettamine, they may be watching you. Customs watches very closely on rec drugs.
They probably watched to see if you'd stop by your friend's house to pick up the package...
There are some types of SpyWare that LE agencies use that cannot be detected as easily.
When you arrived at the eatery, how far were the uniformed cops into eating their meals? I do not think they read your mind and then decided to meet you when you arrived. I would say coincidence.
You were...