13 lines
273 B
Ruby
13 lines
273 B
Ruby
# frozen_string_literal: true
|
|
|
|
class GithubUsersController < ApplicationController
|
|
def index
|
|
@users = GithubUser.all
|
|
render json: @users.to_json
|
|
end
|
|
|
|
def show
|
|
@user = GithubUser.find_by_username(params[:username])
|
|
render json: @user.to_json
|
|
end
|
|
end
|