The vote came as Iraq 's president said Iraqi forces will be ready to take over the country 's security by the end of next year and predicted that British troops will be able to leave Iraq at that time .