Fixed main issue