Rails.application.routes.draw do

  devise_for :users
  get 'login/index'
  root 'login#index'

  resources :costs
  resources :incomes
  resources :categories
  resources :transactions
end

Rails.application.routes.draw do
  devise_for :users
  get 'login/index'
  resources :transactions

  authenticated :user do
    root 'transactions#index', as: "authenticated_root"
  end

  root 'login#index'
  resources :costs
  resources :incomes
  resources :categories
end

Change root based on whether or not the user is signed in
Change root based on whether or not the user is signed in
