This is in Shattered Pixel Dungeon. Went into the shop after getting enough money to buy the Ankh and was followed by a bat. Without paying attention I fought the bat and my shocking sword’s ability went off twice, bouncing into the shopkeep and making him leave. Maybe I’m just a bit salty and it’s my fault for not paying attention to the first hit/warning from the shopkeep, but I don’t think the shocking sword enchantment should threaten the shopkeep like that.
I feel your pain. There’re so many ways to scare the shopkeeper away. Any threat will do.