Updated ddl. Changed sendtoaddress to sendfrom.

This commit is contained in:
Akinwale Ariwodola 2017-09-23 20:31:45 +01:00
parent a408b4e9d3
commit f7e3da2880
2 changed files with 2 additions and 2 deletions

2
app.js
View file

@ -586,7 +586,7 @@ const doSendBalance = (message, callback) => {
};
const sendLbcToAddress = (address, amount, callback) => {
request.post({ url: config.lbrycrd.rpcurl, json: { method: 'sendtoaddress', params: [address, amount] } }, (err, resp, body) => {
request.post({ url: config.lbrycrd.rpcurl, json: { method: 'sendfrom', params: [config.lbrycrd.account, address, amount] } }, (err, resp, body) => {
if (err || body.error) {
return callback(err || body.error, null);
}

View file

@ -3,7 +3,7 @@ CREATE TABLE Users
`Id` BIGINT UNSIGNED NOT NULL AUTO_INCREMENT,
`Username` VARCHAR(20) NOT NULL,
`Balance` DECIMAL(18,8) UNSIGNED DEFAULT 0 NOT NULL,
`DepositAddress` VARCHAR(34) CHARACTER SET latin1 COLLATE latin1_general_ci NOT NULL,
`DepositAddress` VARCHAR(34) CHARACTER SET latin1 COLLATE latin1_general_ci,
`Created` DATETIME NOT NULL,
PRIMARY KEY `PK_UserId` (`Id`),
UNIQUE KEY `Idx_RedditUsername` (`Username`),