Fix for None-type excpetion in case of empty string tag