The issue is in how u are comparing the color in code. When we call turtle.color() it return a tuple (pen_color , fill_color). And turtle.color is a method so comparing will not work.
This can be done depending on what color u want to access either pen_color or fiil_color.
turtle.color("green")
turtle.color()
('green', 'green')
turtle.color()[0] #pen_color
("green")
turtle.color()[1] #fill_color
("green")
turtle.color()==("green")
False
turtle.color()==('green', 'green')
True
turtle.color()[1] == "green"
True
turtle.color()[0] == "green"
True