Is this a regular diswashing soap? Did u get rid of the flies? How many times did u spray and at what concentration?Personally I use Dawn dishwashing soap dissolved in warm water and mist the areas around and on the plant.
I have done this when the buds are growing also with no negative effects.