I created this circuit with an Arduino, flame sensor, relay and a fan. The flame sensor detects a flame when the analog read gets to low. When the flame sensor detects a flame, the Arduino sends a signal through the relay to power the fan, This puts out the fire which the sensor will also detect and when the read gets high again the fan is turned off.

https://wcu.hosted.panopto.com/Panopto/Pages/Viewer.aspx?id=99fa72ba-9828-4d7c-a363-b0c9003d91a6