Added in an isset check because if you set a flash type that is not in o...

...ur expected index it will throw a undefined index error