Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Admin - banks deposits ( 500 Internal Server Error after accept it) #24

Open
openbooknoobdeveloper opened this issue Nov 13, 2018 · 5 comments

Comments

@openbooknoobdeveloper
Copy link

Admin banks deposits 500 Internal Server Error after accept it

adm

Request URL: http://192.111.0.111/admin/deposits/banks/1
Request Method: POST
Status Code: 500 Internal Server Error
Remote Address: 192.111.0.111:80
Referrer Policy: no-referrer-when-downgrade
Connection: keep-alive
Content-Length: 643
Content-Type: text/html; charset=utf-8
Date: Tue, 13 Nov 2018 14:50:40 GMT
Server: nginx/1.14.0 + Phusion Passenger 5.3.7
Status: 500 Internal Server Error
X-Powered-By: Phusion Passenger 5.3.7
X-Request-Id: b01fd919-68cf-4399-8e19-9dc6420fc0ae
X-Runtime: 0.044899
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8
Accept-Encoding: gzip, deflate
Accept-Language: en-US,en;q=0.9,pt-BR;q=0.8,pt;q=0.7,es;q=0.6,it;q=0.5,ja;q=0.4
Cache-Control: max-age=0
Connection: keep-alive
Content-Length: 140
Content-Type: application/x-www-form-urlencoded
Cookie: _peatio_session=2c7e900abcdd42a5cb0e3da295b04aaa; XSRF-TOKEN=d2FA5zVQJxVIwN%2Ff3FHkj4Ag%2Bm%2B5cJRf7Npn2RoVILg%3D; market_id=btccny; sound=true; range_switch=60; type_switch=candlestick; main_indicator_switch=MA; indicator_switch=MACD
Host: http://192.111.0.111
Origin: http://192.111.0.111
Referer: http://192.111.0.111/admin/deposits/banks/1
Upgrade-Insecure-Requests: 1
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.102 Safari/537.36
utf8: ✓
_method: patch
authenticity_token: d2FA5zVQJxVIwN/f3FHkj4Ag+m+5cJRf7Npn2RoVILg=
deposits_bank[txid]: 1
commit: Accept
@pankaj9310
Copy link
Collaborator

Check production log for more details
Use tail -f log/production.log

@openbooknoobdeveloper
Copy link
Author

@pankaj9310 thank you, I got this error.


I, [2018-11-13T12:36:35.913436 #5593]  INFO -- : Processing by Admin::Deposits::BanksController#update as HTML
I, [2018-11-13T12:36:35.913476 #5593]  INFO -- :   Parameters: {"utf8"=>"✓", "authenticity_token"=>"8uqnvJ39wAhODTvjc5m3zzq2wy+m/eots3PQLk3YZjE=", "deposits_bank"=>{"txid"=>"9999"}, "commit"=>"Accept", "id"=>"1"}
I, [2018-11-13T12:36:35.984604 #5593]  INFO -- : Completed 500 Internal Server Error in 71ms
F, [2018-11-13T12:36:35.985490 #5593] FATAL -- : 
NameError (undefined local variable or method `c' for #<Deposits::Bank:0x007f06022872b0>):
  app/models/deposit.rb:124:in `aggregate_funds'
  app/models/deposits/bank.rb:10:in `block in charge!'
  app/models/deposits/bank.rb:8:in `charge!'
  app/controllers/admin/deposits/banks_controller.rb:29:in `update'
  lib/middleware/security.rb:11:in `call'

@pankaj9310
Copy link
Collaborator

@openbooknoobdeveloper
change line number 124 in models/deposit.rb

replace c with channel.currency_obj

if channel.currency_obj.code == 'ETH'

@vodetype
Copy link

vodetype commented Feb 6, 2019

thanks already solved

@pblab-dev

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants