Move gist_title function call after condition