USA being a middleman is likely due to convenience allowed by free trade. Depending on where the coffee is processed/roasted, many logistic chains can adapt so products aren't simply imported/exported through the USA with tariffs applied. I'm by no means super educated on tariffs, but I've read that products can be shipped to Canada through the USA without tariffs. Probably if the product isn't modified in any way, and Canada is the intended destination.
It'll be interesting to see what happens - I've been brewing Canada roasted coffee for years. My roaster just raised their prices by about 4%.