Fixed bug with getting colour from images