Sha256: 5b1199757db23e2f76c5ce99a63337f1f6a0e236923bf93aa540c66dcb0d2ea8
Contents?: true
Size: 436 Bytes
Versions: 16
Compression:
Stored size: 436 Bytes
Contents
require_dependency "landable/api_controller" module Landable module Api class DirectoriesController < ApiController def index ids = params[:ids] if params[:ids].present? and params[:ids].is_a? Array ids ||= ['/'] listings = ids.map { |id| Directory.listing id } respond_with listings end def show respond_with Directory.listing(params[:id]) end end end end
Version data entries
16 entries across 16 versions & 1 rubygems