     end
   end
 
+  @spec path_directory_info(Plug.Conn.t, String.t)
+        :: {:ok, Plug.Conn.t, String.t} | {:error, Plug.Conn.t}
+
   defp path_directory_info(conn, path) do
     case :prim_file.read_file_info(path) do
       {:ok, file_info(type: :directory) = _file_info} ->

      footer_html(host)]
  end

  defp dir_file_list(dirpath, sortfn) do
    {:ok, list} = :prim_file.list_dir(dirpath)
    Enum.sort(

  end

  # null directory is allowed here

  @spec allowed?([String.t], [String.t], [String.t] | nil) :: boolean()

  defp allowed?(_only, _prefix, nil), do: false
  defp allowed?([], [], _list), do: true
  defp allowed?(_only, _prefix, []), do: false
