if ($template->query(name => 'temperature' or $template->query(name => 'cloud_cover') { # The code to find out what the weather is like goes here }