Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def exec_no_cache(sql, name, binds)
- type_casted_binds = binds.map { |attr| type_cast(attr.value_for_database) }
- log(sql, name, binds) { @connection.async_exec(sql, type_casted_binds) } [HIGHLIGHTING THIS LINE]
- end
- def exec_cache(sql, name, binds)
- Kegans-MacBook-Pro:MyApp Kegan$ rails s
- Array values in the parameter to `Gem.paths=` are deprecated.
- Please use a String or nil.
- An Array ({"GEM_PATH"=>["/Users/Kegan/.rvm/gems/ruby-2.3.1", "/Users/Kegan/.rvm/gems/ruby-2.3.1@global"]}) was passed in from bin/rails:3:in `load'
- => Booting Puma
- => Rails 5.0.0.rc1 application starting in development on http://localhost:3000
- => Run `rails server -h` for more startup options
- [Simple Form] Simple Form is not configured in the application and will use the default values. Use `rails generate simple_form:install` to generate the Simple Form configuration.
- Puma starting in single mode...
- * Version 3.4.0 (ruby 2.3.1-p112), codename: Owl Bowl Brawl
- * Min threads: 5, max threads: 5
- * Environment: development
- * Listening on tcp://localhost:3000
- Use Ctrl-C to stop
- Started GET "/" for ::1 at 2016-06-10 14:15:05 -0600
- ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"
- Processing by HomeController#index as HTML
- Rendering home/index.html.erb within layouts/application
- User Load (0.9ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT $2 [["id", 6], ["LIMIT", 1]]
- Link Load (0.5ms) SELECT "links".* FROM "links" ORDER BY "links"."id" DESC LIMIT $1 [["LIMIT", 1]]
- CACHE (0.0ms) SELECT "links".* FROM "links" ORDER BY "links"."id" DESC LIMIT $1 [["LIMIT", 1]]
- User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT $2 [["id", 6], ["LIMIT", 1]]
- (1.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = $1 AND "votes"."votable_type" = $2 AND "votes"."vote_flag" = $3 AND "votes"."vote_scope" IS NULL [["votable_id", 8], ["votable_type", "Link"], ["vote_flag", true]]
- (0.4ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = $1 AND "votes"."votable_type" = $2 AND "votes"."vote_flag" = $3 AND "votes"."vote_scope" IS NULL [["votable_id", 8], ["votable_type", "Link"], ["vote_flag", false]]
- Forum Load (0.5ms) SELECT "forums".* FROM "forums" ORDER BY "forums"."id" DESC LIMIT $1 [["LIMIT", 1]]
- CACHE (0.0ms) SELECT "forums".* FROM "forums" ORDER BY "forums"."id" DESC LIMIT $1 [["LIMIT", 1]]
- CACHE (0.0ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT $2 [["id", 6], ["LIMIT", 1]]
- Rendered home/index.html.erb within layouts/application (84.0ms)
- Completed 200 OK in 291ms (Views: 263.2ms | ActiveRecord: 16.4ms)
- Started GET "/cable" for ::1 at 2016-06-10 14:15:05 -0600
- Started GET "/cable/" [WebSocket] for ::1 at 2016-06-10 14:15:05 -0600
- Successfully upgraded to WebSocket (REQUEST_METHOD: GET, HTTP_CONNECTION: Upgrade, HTTP_UPGRADE: websocket)
- User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT $2 [["id", 6], ["LIMIT", 1]]
- [ActionCable] [joshgamer1@gmail.com] Registered connection (Z2lkOi8va29ob3JkL1VzZXIvNg)
- [ActionCable] [joshgamer1@gmail.com] RoomChannel is transmitting the subscription confirmation
- [ActionCable] [joshgamer1@gmail.com] RoomChannel is streaming from room_channel
- Started GET "/users/edit" for ::1 at 2016-06-10 14:15:10 -0600
- Processing by Devise::RegistrationsController#edit as HTML
- User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT $2 [["id", 6], ["LIMIT", 1]]
- DEPRECATION WARNING: [Devise] Changing the sanitized parameters through "Devise::ParameterSanitizer#for(sign_up) is deprecated and it will be removed from Devise 4.2.
- Please use the `permit` method:
- devise_parameter_sanitizer.permit(:sign_up) do |user|
- # Your block here.
- end
- (called from configure_permitted_parameters at /Users/Kegan/Documents/AppDev/myApp/app/controllers/application_controller.rb:10)
- DEPRECATION WARNING: [Devise] Changing the sanitized parameters through "Devise::ParameterSanitizer#for(account_update) is deprecated and it will be removed from Devise 4.2.
- Please use the `permit` method:
- devise_parameter_sanitizer.permit(:account_update) do |user|
- # Your block here.
- end
- (called from configure_permitted_parameters at /Users/Kegan/Documents/AppDev/MyApp/app/controllers/application_controller.rb:11)
- Rendering devise/registrations/edit.html.erb within layouts/application
- Rendered devise/registrations/edit.html.erb within layouts/application (14.5ms)
- Completed 200 OK in 81ms (Views: 77.5ms | ActiveRecord: 0.5ms)
- Started DELETE "/users" for ::1 at 2016-06-10 14:15:18 -0600
- Processing by Devise::RegistrationsController#destroy as HTML
- Parameters: {"utf8"=>"✓", "authenticity_token"=>"9Ou51KmxWKW+SheDAZl86Rtb8jMQBDSVZswiwfkHxUpg2b4DA/9xneXzPXsckQ7V6oy6MqBkWPctS24X1Z9V7w==", "user"=>{"avatar"=>"", "name"=>"Joshua Artos", "email"=>"joshgamer1@gmail.com", "password"=>"[FILTERED]", "bio"=>"Josh. Kick ass at video games.", "location"=>"Fort Collins", "age"=>"18", "gender"=>"Doesn't Matter", "interestedin"=>"Netfix", "major"=>"Doesn't Matter", "twitterurl"=>"", "instagramurl"=>"", "current_password"=>"[FILTERED]"}, "commit"=>"Update"}
- User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT $2 [["id", 6], ["LIMIT", 1]]
- DEPRECATION WARNING: [Devise] Changing the sanitized parameters through "Devise::ParameterSanitizer#for(sign_up) is deprecated and it will be removed from Devise 4.2.
- Please use the `permit` method:
- devise_parameter_sanitizer.permit(:sign_up) do |user|
- # Your block here.
- end
- (called from configure_permitted_parameters at /Users/Kegan/Documents/AppDev/MyApp/app/controllers/application_controller.rb:10)
- DEPRECATION WARNING: [Devise] Changing the sanitized parameters through "Devise::ParameterSanitizer#for(account_update) is deprecated and it will be removed from Devise 4.2.
- Please use the `permit` method:
- devise_parameter_sanitizer.permit(:account_update) do |user|
- # Your block here.
- end
- (called from configure_permitted_parameters at /Users/Kegan/Documents/MyApp/Kohord/app/controllers/application_controller.rb:11)
- (0.1ms) BEGIN
- SQL (2.3ms) DELETE FROM "users" WHERE "users"."id" = $1 [["id", 6]]
- (0.1ms) ROLLBACK
- Completed 500 Internal Server Error in 10ms (ActiveRecord: 3.0ms)
- ActiveRecord::InvalidForeignKey (PG::ForeignKeyViolation: ERROR: update or delete on table "users" violates foreign key constraint "fk_rails_03de2dc08c" on table "comments"
- DETAIL: Key (id)=(6) is still referenced from table "comments".
- : DELETE FROM "users" WHERE "users"."id" = $1):
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `async_exec'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `block in exec_no_cache'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/abstract_adapter.rb:566:in `block in log'
- activesupport (5.0.0.rc1) lib/active_support/notifications/instrumenter.rb:21:in `instrument'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/abstract_adapter.rb:560:in `log'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/postgresql_adapter.rb:598:in `exec_no_cache'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/postgresql_adapter.rb:587:in `execute_and_clear'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/postgresql/database_statements.rb:116:in `exec_delete'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/abstract/database_statements.rb:140:in `delete'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/abstract/query_cache.rb:14:in `delete'
- activerecord (5.0.0.rc1) lib/active_record/relation.rb:543:in `delete_all'
- activerecord (5.0.0.rc1) lib/active_record/persistence.rb:525:in `destroy_row'
- activerecord (5.0.0.rc1) lib/active_record/counter_cache.rb:141:in `destroy_row'
- activerecord (5.0.0.rc1) lib/active_record/locking/optimistic.rb:115:in `destroy_row'
- activerecord (5.0.0.rc1) lib/active_record/persistence.rb:184:in `destroy'
- activerecord (5.0.0.rc1) lib/active_record/callbacks.rb:283:in `block in destroy'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:126:in `call'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:506:in `block (2 levels) in compile'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:455:in `call'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:101:in `__run_callbacks__'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:750:in `_run_destroy_callbacks'
- activerecord (5.0.0.rc1) lib/active_record/callbacks.rb:283:in `destroy'
- activerecord (5.0.0.rc1) lib/active_record/transactions.rb:314:in `block in destroy'
- activerecord (5.0.0.rc1) lib/active_record/transactions.rb:395:in `block in with_transaction_returning_status'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/abstract/database_statements.rb:232:in `block in transaction'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/abstract/transaction.rb:189:in `within_new_transaction'
- activerecord (5.0.0.rc1) lib/active_record/connection_adapters/abstract/database_statements.rb:232:in `transaction'
- activerecord (5.0.0.rc1) lib/active_record/transactions.rb:211:in `transaction'
- activerecord (5.0.0.rc1) lib/active_record/transactions.rb:392:in `with_transaction_returning_status'
- activerecord (5.0.0.rc1) lib/active_record/transactions.rb:314:in `destroy'
- devise (4.1.1) app/controllers/devise/registrations_controller.rb:66:in `destroy'
- actionpack (5.0.0.rc1) lib/action_controller/metal/basic_implicit_render.rb:4:in `send_action'
- actionpack (5.0.0.rc1) lib/abstract_controller/base.rb:181:in `process_action'
- actionpack (5.0.0.rc1) lib/action_controller/metal/rendering.rb:30:in `process_action'
- actionpack (5.0.0.rc1) lib/abstract_controller/callbacks.rb:20:in `block in process_action'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:126:in `call'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:506:in `block (2 levels) in compile'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:455:in `call'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:101:in `__run_callbacks__'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:750:in `_run_process_action_callbacks'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:90:in `run_callbacks'
- actionpack (5.0.0.rc1) lib/abstract_controller/callbacks.rb:19:in `process_action'
- actionpack (5.0.0.rc1) lib/action_controller/metal/rescue.rb:31:in `process_action'
- actionpack (5.0.0.rc1) lib/action_controller/metal/instrumentation.rb:32:in `block in process_action'
- activesupport (5.0.0.rc1) lib/active_support/notifications.rb:164:in `block in instrument'
- activesupport (5.0.0.rc1) lib/active_support/notifications/instrumenter.rb:21:in `instrument'
- activesupport (5.0.0.rc1) lib/active_support/notifications.rb:164:in `instrument'
- actionpack (5.0.0.rc1) lib/action_controller/metal/instrumentation.rb:30:in `process_action'
- actionpack (5.0.0.rc1) lib/action_controller/metal/params_wrapper.rb:248:in `process_action'
- activerecord (5.0.0.rc1) lib/active_record/railties/controller_runtime.rb:18:in `process_action'
- actionpack (5.0.0.rc1) lib/abstract_controller/base.rb:126:in `process'
- actionview (5.0.0.rc1) lib/action_view/rendering.rb:30:in `process'
- actionpack (5.0.0.rc1) lib/action_controller/metal.rb:190:in `dispatch'
- actionpack (5.0.0.rc1) lib/action_controller/metal.rb:262:in `dispatch'
- actionpack (5.0.0.rc1) lib/action_dispatch/routing/route_set.rb:50:in `dispatch'
- actionpack (5.0.0.rc1) lib/action_dispatch/routing/route_set.rb:32:in `serve'
- actionpack (5.0.0.rc1) lib/action_dispatch/routing/mapper.rb:16:in `block in <class:Constraints>'
- actionpack (5.0.0.rc1) lib/action_dispatch/routing/mapper.rb:46:in `serve'
- actionpack (5.0.0.rc1) lib/action_dispatch/journey/router.rb:39:in `block in serve'
- actionpack (5.0.0.rc1) lib/action_dispatch/journey/router.rb:26:in `each'
- actionpack (5.0.0.rc1) lib/action_dispatch/journey/router.rb:26:in `serve'
- actionpack (5.0.0.rc1) lib/action_dispatch/routing/route_set.rb:725:in `call'
- actionview (5.0.0.rc1) lib/action_view/digestor.rb:12:in `call'
- warden (1.2.6) lib/warden/manager.rb:35:in `block in call'
- warden (1.2.6) lib/warden/manager.rb:34:in `catch'
- warden (1.2.6) lib/warden/manager.rb:34:in `call'
- rack (2.0.0.rc1) lib/rack/etag.rb:25:in `call'
- rack (2.0.0.rc1) lib/rack/conditional_get.rb:38:in `call'
- rack (2.0.0.rc1) lib/rack/head.rb:12:in `call'
- rack (2.0.0.rc1) lib/rack/session/abstract/id.rb:222:in `context'
- rack (2.0.0.rc1) lib/rack/session/abstract/id.rb:216:in `call'
- actionpack (5.0.0.rc1) lib/action_dispatch/middleware/cookies.rb:613:in `call'
- activerecord (5.0.0.rc1) lib/active_record/migration.rb:552:in `call'
- actionpack (5.0.0.rc1) lib/action_dispatch/middleware/callbacks.rb:38:in `block in call'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:97:in `__run_callbacks__'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:750:in `_run_call_callbacks'
- activesupport (5.0.0.rc1) lib/active_support/callbacks.rb:90:in `run_callbacks'
- actionpack (5.0.0.rc1) lib/action_dispatch/middleware/callbacks.rb:36:in `call'
- actionpack (5.0.0.rc1) lib/action_dispatch/middleware/executor.rb:12:in `call'
- actionpack (5.0.0.rc1) lib/action_dispatch/middleware/remote_ip.rb:79:in `call'
- actionpack (5.0.0.rc1) lib/action_dispatch/middleware/debug_exceptions.rb:49:in `call'
- web-console (2.3.0) lib/web_console/middleware.rb:28:in `block in call'
- web-console (2.3.0) lib/web_console/middleware.rb:18:in `catch'
- web-console (2.3.0) lib/web_console/middleware.rb:18:in `call'
- actionpack (5.0.0.rc1) lib/action_dispatch/middleware/show_exceptions.rb:31:in `call'
- railties (5.0.0.rc1) lib/rails/rack/logger.rb:36:in `call_app'
- railties (5.0.0.rc1) lib/rails/rack/logger.rb:24:in `block in call'
- activesupport (5.0.0.rc1) lib/active_support/tagged_logging.rb:70:in `block in tagged'
- activesupport (5.0.0.rc1) lib/active_support/tagged_logging.rb:26:in `tagged'
- activesupport (5.0.0.rc1) lib/active_support/tagged_logging.rb:70:in `tagged'
- railties (5.0.0.rc1) lib/rails/rack/logger.rb:24:in `call'
- actionpack (5.0.0.rc1) lib/action_dispatch/middleware/request_id.rb:24:in `call'
- rack (2.0.0.rc1) lib/rack/method_override.rb:22:in `call'
- rack (2.0.0.rc1) lib/rack/runtime.rb:22:in `call'
- activesupport (5.0.0.rc1) lib/active_support/cache/strategy/local_cache_middleware.rb:28:in `call'
- actionpack (5.0.0.rc1) lib/action_dispatch/middleware/executor.rb:12:in `call'
- actionpack (5.0.0.rc1) lib/action_dispatch/middleware/static.rb:136:in `call'
- rack (2.0.0.rc1) lib/rack/sendfile.rb:111:in `call'
- railties (5.0.0.rc1) lib/rails/engine.rb:522:in `call'
- puma (3.4.0) lib/puma/configuration.rb:224:in `call'
- puma (3.4.0) lib/puma/server.rb:569:in `handle_request'
- puma (3.4.0) lib/puma/server.rb:406:in `process_client'
- puma (3.4.0) lib/puma/server.rb:271:in `block in run'
- puma (3.4.0) lib/puma/thread_pool.rb:114:in `block in spawn_thread'
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/actionpack-5.0.0.rc1/lib/action_dispatch/middleware/templates/rescues/diagnostics.html.erb within rescues/layout
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/actionpack-5.0.0.rc1/lib/action_dispatch/middleware/templates/rescues/_source.html.erb
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/actionpack-5.0.0.rc1/lib/action_dispatch/middleware/templates/rescues/_source.html.erb (6.5ms)
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/actionpack-5.0.0.rc1/lib/action_dispatch/middleware/templates/rescues/_trace.html.erb
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/actionpack-5.0.0.rc1/lib/action_dispatch/middleware/templates/rescues/_trace.html.erb (3.8ms)
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/actionpack-5.0.0.rc1/lib/action_dispatch/middleware/templates/rescues/_request_and_response.html.erb
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/actionpack-5.0.0.rc1/lib/action_dispatch/middleware/templates/rescues/_request_and_response.html.erb (1.6ms)
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/actionpack-5.0.0.rc1/lib/action_dispatch/middleware/templates/rescues/diagnostics.html.erb within rescues/layout (52.5ms)
- DEPRECATION WARNING: #original_exception is deprecated. Use #cause instead. (called from status_code_with_paginate at /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/will_paginate-3.1.0/lib/will_paginate/railtie.rb:49)
- DEPRECATION WARNING: Accessing mime types via constants is deprecated. Please change `Mime::HTML` to `Mime[:html]`. (called from const_missing at /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/actionpack-5.0.0.rc1/lib/action_dispatch/http/mime_type.rb:52)
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/index.html.erb
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/_markup.html.erb (0.7ms)
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/console.js.erb within layouts/javascript
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/_inner_console_markup.html.erb within layouts/inlined_string
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/_inner_console_markup.html.erb within layouts/inlined_string (0.2ms)
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/_prompt_box_markup.html.erb within layouts/inlined_string
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/_prompt_box_markup.html.erb within layouts/inlined_string (0.6ms)
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/style.css.erb within layouts/inlined_string
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/style.css.erb within layouts/inlined_string (0.2ms)
- DEPRECATION WARNING: Accessing mime types via constants is deprecated. Please change `Mime::WEB_CONSOLE_V2` to `Mime[:web_console_v2]`. (called from const_missing at /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/actionpack-5.0.0.rc1/lib/action_dispatch/http/mime_type.rb:52)
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/console.js.erb within layouts/javascript (42.2ms)
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/main.js.erb within layouts/javascript
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/main.js.erb within layouts/javascript (0.8ms)
- Rendering /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/error_page.js.erb within layouts/javascript
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/error_page.js.erb within layouts/javascript (0.8ms)
- Rendered /Users/KingKegan/.rvm/gems/ruby-2.3.1/gems/web-console-2.3.0/lib/web_console/templates/index.html.erb (94.0ms)
- [ActionCable] [joshgamer1@gmail.com] Finished "/cable/" [WebSocket] for ::1 at 2016-06-10 14:15:18 -0600
- [ActionCable] [joshgamer1@gmail.com] RoomChannel stopped streaming from room_channel
- Started GET "/cable" for ::1 at 2016-06-10 14:15:21 -0600
- Started GET "/cable/" [WebSocket] for ::1 at 2016-06-10 14:15:21 -0600
- Successfully upgraded to WebSocket (REQUEST_METHOD: GET, HTTP_CONNECTION: Upgrade, HTTP_UPGRADE: websocket)
- User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT $2 [["id", 6], ["LIMIT", 1]]
- [ActionCable] [joshgamer1@gmail.com] Registered connection (Z2lkOi8va29ob3JkL1VzZXIvNg)
- [ActionCable] [joshgamer1@gmail.com] RoomChannel is transmitting the subscription confirmation
- [ActionCable] [joshgamer1@gmail.com] RoomChannel is streaming from room_channel
- Started PUT "/users" for ::1 at 2016-06-10 14:15:28 -0600
- Processing by Devise::RegistrationsController#update as HTML
- Parameters: {"utf8"=>"✓", "authenticity_token"=>"MfnKmUW4Xfct9NyjC9bbwfEDusLvTYXHQRuqyltHr1yly81O7/Z0z3ZN9lsW3qn9ANTyw18t6aUKnOYcd98/+Q==", "user"=>{"avatar"=>"", "name"=>"Joshua Artos", "email"=>"joshgamer1@gmail.com", "password"=>"[FILTERED]", "bio"=>"Josh. Kick ass at video games.", "location"=>"Fort Collins", "age"=>"18", "gender"=>"Doesn't Matter", "interestedin"=>"Netfix", "major"=>"Doesn't Matter", "twitterurl"=>"", "instagramurl"=>"", "current_password"=>"[FILTERED]"}, "commit"=>"Update"}
- User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT $2 [["id", 6], ["LIMIT", 1]]
- DEPRECATION WARNING: [Devise] Changing the sanitized parameters through "Devise::ParameterSanitizer#for(sign_up) is deprecated and it will be removed from Devise 4.2.
- Please use the `permit` method:
- devise_parameter_sanitizer.permit(:sign_up) do |user|
- # Your block here.
- end
- (called from configure_permitted_parameters at /Users/Kegan/Documents/AppDev/MyApp/app/controllers/application_controller.rb:10)
- DEPRECATION WARNING: [Devise] Changing the sanitized parameters through "Devise::ParameterSanitizer#for(account_update) is deprecated and it will be removed from Devise 4.2.
- Please use the `permit` method:
- devise_parameter_sanitizer.permit(:account_update) do |user|
- # Your block here.
- end
- (called from configure_permitted_parameters at /Users/Kegan/Documents/AppDev/MyApp/app/controllers/application_controller.rb:11)
- User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT $2 [["id", 6], ["LIMIT", 1]]
- (0.2ms) BEGIN
- (0.2ms) COMMIT
- Redirected to http://localhost:3000/
- Completed 302 Found in 94ms (ActiveRecord: 1.3ms)
- Started GET "/" for ::1 at 2016-06-10 14:15:28 -0600
- Processing by HomeController#index as HTML
- Rendering home/index.html.erb within layouts/application
- User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT $2 [["id", 6], ["LIMIT", 1]]
- Link Load (0.3ms) SELECT "links".* FROM "links" ORDER BY "links"."id" DESC LIMIT $1 [["LIMIT", 1]]
- CACHE (0.0ms) SELECT "links".* FROM "links" ORDER BY "links"."id" DESC LIMIT $1 [["LIMIT", 1]]
- User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT $2 [["id", 6], ["LIMIT", 1]]
- (0.5ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = $1 AND "votes"."votable_type" = $2 AND "votes"."vote_flag" = $3 AND "votes"."vote_scope" IS NULL [["votable_id", 8], ["votable_type", "Link"], ["vote_flag", true]]
- (0.9ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = $1 AND "votes"."votable_type" = $2 AND "votes"."vote_flag" = $3 AND "votes"."vote_scope" IS NULL [["votable_id", 8], ["votable_type", "Link"], ["vote_flag", false]]
- Forum Load (0.3ms) SELECT "forums".* FROM "forums" ORDER BY "forums"."id" DESC LIMIT $1 [["LIMIT", 1]]
- CACHE (0.0ms) SELECT "forums".* FROM "forums" ORDER BY "forums"."id" DESC LIMIT $1 [["LIMIT", 1]]
- CACHE (0.0ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT $2 [["id", 6], ["LIMIT", 1]]
- Rendered home/index.html.erb within layouts/application (14.5ms)
- Completed 200 OK in 56ms (Views: 51.7ms | ActiveRecord: 2.8ms)
- [ActionCable] [joshgamer1@gmail.com] Finished "/cable/" [WebSocket] for ::1 at 2016-06-10 14:15:28 -0600
- [ActionCable] [joshgamer1@gmail.com] RoomChannel stopped streaming from room_channel
- Started GET "/cable" for ::1 at 2016-06-10 14:15:28 -0600
- Started GET "/cable/" [WebSocket] for ::1 at 2016-06-10 14:15:28 -0600
- class User < ApplicationRecord
- # Include default devise modules. Others available are:
- # :confirmable, :lockable, :timeoutable and :omniauthable
- devise :database_authenticatable, :registerable,
- :recoverable, :rememberable, :trackable, :validatable
- has_many :forums
- has_many :links
- has_many :discussions
- has_many :comments
- has_many :chats
- has_many :chatrooms, through: :chats
- # It returns the articles whose titles contain one or more words that form the query
- def self.search(query)
- # where(:title, query) -> This would return an exact match of the query
- where("name like ?", "%#{query}%")
- end
- has_attached_file :avatar, :styles => { :medium => "300x300>", :thumb => "100x100#" }, :default_url => "/images/:style/missingMike.png"
- validates_attachment_content_type :avatar, :content_type => /Aimage/.*Z/
- end
- class UsersController < ApplicationController
- def index
- if params[:search]
- @users = User.search(params[:search])
- @users = @users.paginate(:page => params[:page], :per_page => 5)
- else
- @users = User.paginate(:page => params[:page], :per_page => 2)
- end
- end
- def show
- @user = User.find(params[:id])
- @user_links = @user.links
- @user_comments = @user.comments
- @user_forums = @user.forums
- @user_discussions = @user.discussions
- end
- def goAnonymous
- @user = User.find(params[:id])
- @user.anonymous = true
- redirect_to :back
- end
- def leaveAnonymous
- @user = User.find(params[:id])
- @user.anonymous = false
- redirect_to :back
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement