Browse Source

修改判断用户是否登录

tags/v1
sylor_huang@126.com 6 years ago
parent
commit
594da4dc8a
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      app/controllers/settings_controller.rb

+ 1
- 1
app/controllers/settings_controller.rb View File

@@ -1,6 +1,6 @@
class SettingsController < ApplicationController
def show
@old_projects_url = nil
@old_projects_url = "https://www.trustie.net/users/#{current_user.try(:login)}/projects" if current_user.present?
@old_projects_url = "https://www.trustie.net/users/#{current_user.try(:login)}/projects" if User.current.logged?
end
end

Loading…
Cancel
Save