Switched all '==' to '==='.
created 'createFractalImage' function
Refactored common fractal rendering code into createFractalImage function.