File tree 3 files changed +16
-10
lines changed 3 files changed +16
-10
lines changed Original file line number Diff line number Diff line change @@ -107,21 +107,18 @@ def update
107
107
108
108
return head ( :forbidden ) unless @user == current_user || admin_of_premium_team?
109
109
110
- if @user . update_attributes! ( user_update_params )
110
+ if @user . update_attributes ( user_update_params )
111
111
@user . activate if @user . has_badges? && !@user . active?
112
112
flash . now [ :notice ] = "The changes have been applied to your profile."
113
113
expire_fragment ( @user . daily_cache_key )
114
+ else
115
+ flash . now [ :notice ] = "There were issues updating your profile."
114
116
end
115
117
116
- auto_upload = params [ :user ] [ :auto_upload ]
117
- if auto_upload
118
- head :ok
118
+ if admin_of_premium_team?
119
+ redirect_to ( teamname_url ( slug : @user . team . slug , full : :preview ) )
119
120
else
120
- if admin_of_premium_team?
121
- redirect_to ( teamname_url ( slug : @user . team . slug , full : :preview ) )
122
- else
123
- redirect_to ( edit_user_url ( @user ) )
124
- end
121
+ redirect_to ( edit_user_url ( @user ) )
125
122
end
126
123
end
127
124
Original file line number Diff line number Diff line change 1
1
class ResumeUploader < CoderwallUploader
2
2
3
3
def extension_white_list
4
- %w( pdf doc docx jpg jpeg gif png )
4
+ %w( pdf doc docx odt txt jpg jpeg png )
5
5
end
6
6
7
7
end
Original file line number Diff line number Diff line change
1
+ RSpec . describe ResumeUploadsController , :type => :routing do
2
+ describe 'routing' do
3
+
4
+ it 'routes to #create' do
5
+ expect ( post ( '/resume_uploads' ) ) . to route_to ( { controller : 'resume_uploads' , action : 'create' } )
6
+ end
7
+
8
+ end
9
+ end
You can’t perform that action at this time.
0 commit comments