An alternative approach to the one proposed by @Friede is override.aes
.
+ guides(fill = guide_legend(override.aes = list(colour = "black")))
This method, on the other hand, directly injects aesthetic settings into the legend drawing calls, which can be useful if you want different behavior for specific layers or guides.