Skip to content
Snippets Groups Projects
Commit 15ab81f8 authored by James Calfee's avatar James Calfee
Browse files

Configurable image upload server url. #185

parent 7d4c9afc
No related tags found
No related merge requests found
......@@ -350,7 +350,6 @@ function* lookupPreviousOwnerAuthority({payload: {}}) {
}
import {Signature, hash} from 'shared/ecc'
// import request from 'request'
function* uploadImageWatch() {
yield* takeLatest('user/UPLOAD_IMAGE', uploadImage);
......@@ -411,7 +410,7 @@ function* uploadImage({payload: {file, dataUrl, filename = 'image.txt', progress
}
const sig = Signature.signBufferSha256(bufSha, d)
const postUrl = `http://localhost:3234/${username}/${sig.toHex()}`
const postUrl = `${$STM_Config.uploadImage}/${username}/${sig.toHex()}`
fetch(postUrl, {
method: 'post',
......
......@@ -20,7 +20,8 @@ global.$STM_Config = {
ipfs_prefix: config.ipfs_prefix,
disable_signups: config.disable_signups,
read_only_mode: config.read_only_mode,
registrar_fee: config.registrar.fee
registrar_fee: config.registrar.fee,
uploadImage: config.uploadImage,
};
const WebpackIsomorphicTools = require('webpack-isomorphic-tools');
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment