Worked in 2 states and 1 state's company is in another state.

I live & work in Michigan, but worked in Missouri for 2 weeks for a company that's based in Illinois. The W2 from that company took out state taxes for Illinois. Who do I file for under other states worked for, Illinois or Missouri?