From f9437b2fcc7b158acadc506aec0065e0fd48ff42 Mon Sep 17 00:00:00 2001 From: Jasper van Merle <jaspervmerle@gmail.com> Date: Thu, 22 Aug 2019 15:20:26 +0200 Subject: [PATCH] elixir: fix NoMethodError and properly categorize Mix tasks --- lib/docs/filters/elixir/entries.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/docs/filters/elixir/entries.rb b/lib/docs/filters/elixir/entries.rb index 4b518de2..72794f87 100644 --- a/lib/docs/filters/elixir/entries.rb +++ b/lib/docs/filters/elixir/entries.rb @@ -2,7 +2,8 @@ module Docs class Elixir class EntriesFilter < Docs::EntriesFilter def get_name - at_css('h1 .app-vsn').remove + css('h1 .app-vsn').remove + if current_url.path.start_with?('/getting-started') at_css('h1').content.strip.remove(/\.\z/) else @@ -30,6 +31,8 @@ module Docs else if name.start_with?('Phoenix') name.split('.')[0..2].join('.') + elsif name.start_with?('mix ') + 'Mix Tasks' else name.split('.').first end