質問編集履歴

1

sessions_controller.rbを追記しました

2019/07/02 03:19

投稿

YousukeSasaki
YousukeSasaki

スコア12

test CHANGED
File without changes
test CHANGED
@@ -262,6 +262,74 @@
262
262
 
263
263
 
264
264
 
265
+ sessions_controller.rb
266
+
267
+
268
+
269
+ ```
270
+
271
+ # frozen_string_literal: true
272
+
273
+
274
+
275
+ class Users::SessionsController < Devise::SessionsController
276
+
277
+ render layout: 'application'
278
+
279
+ # before_action :configure_sign_in_params, only: [:create]
280
+
281
+
282
+
283
+ # GET /resource/sign_in
284
+
285
+ # def new
286
+
287
+ # super
288
+
289
+ # end
290
+
291
+
292
+
293
+ # POST /resource/sign_in
294
+
295
+ # def create
296
+
297
+ # super
298
+
299
+ # end
300
+
301
+
302
+
303
+ # DELETE /resource/sign_out
304
+
305
+ def destroy
306
+
307
+ redirect_to new_user_session_path
308
+
309
+ super
310
+
311
+ end
312
+
313
+
314
+
315
+ # protected
316
+
317
+
318
+
319
+ # If you have extra params to permit, append them to the sanitizer.
320
+
321
+ # def configure_sign_in_params
322
+
323
+ # devise_parameter_sanitizer.permit(:sign_in, keys: [:attribute])
324
+
325
+ # end
326
+
327
+ end
328
+
329
+ ```
330
+
331
+
332
+
265
333
  ### 試したこと
266
334
 
267
335