Well, if its not working as it should, it not hurts but it doesn't helps either
<?php
if(JFactory::getConfig()->getValue('config.sef')==1) {
$app =& JFactory::getApplication();
$uri = strtolower(substr(str_replace(JURI::base(),"",JURI::getInstance()->tostring()),0,21));
if($uri=="index.php?option=com_")
$app->redirect(JRoute::_(str_replace(JURI::base(),"",JURI::getInstance()->tostring())));
}
?>
Insert this on the top of template's index.php and its gonna be ok. I forgot to update this post after i found solution.