Fixed bug with HEAD