<commit_before>class Nabu

	route 'sitemap' do |r|

		r.get do
			# these @vars are used in templates as well

			@sitemap = CmsPage.published.order(:name)

			# guests can only see visible pages
			@sitemap = @sitemap.visible unless user.logged_in?

			if (@tag = r.params['tag']) && (t = Tag[name: @tag])
				# tag filtering, if set.
				@sitemap = @sitemap.where(tags: t)
			elsif @search = r.params['search']
				# search query, if set.<commit_msg>not that it makes any difference for now..<commit_after>class Nabu

	route 'sitemap' do |r|

		r.get do
			# these @vars are used in templates as well

			@sitemap = CmsPage.published.order(:name)

			# only admin can see private pages
			@sitemap = @sitemap.visible unless user.admin?

			if (@tag = r.params['tag']) && (t = Tag[name: @tag])
				# tag filtering, if set.
				@sitemap = @sitemap.where(tags: t)
			elsif @search = r.params['search']
				# search query, if set.
{'fraction_non_alphanumeric': 0.13577586206896552, 'fraction_numerical': 0.0, 'mean_word_length': 3.184684684684685, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5902730', 'n_tokens_mistral': 383, 'n_tokens_neox': 326, 'n_words': 102}