Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
04845d42
Commit
04845d42
authored
Nov 18, 2014
by
Marek Kotewicz
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1 from cubedro/master
Fixed autoprovider bug
parents
27a8799e
0d526d66
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
autoprovider.js
lib/autoprovider.js
+5
-5
package.json
package.json
+1
-1
No files found.
lib/autoprovider.js
View file @
04845d42
...
...
@@ -14,7 +14,7 @@
You should have received a copy of the GNU Lesser General Public License
along with ethereum.js. If not, see <http://www.gnu.org/licenses/>.
*/
/** @file
websocket
.js
/** @file
autoprovider
.js
* @authors:
* Marek Kotewicz <marek@ethdev.com>
* Marian Oancea <marian@ethdev.com>
...
...
@@ -28,7 +28,7 @@
*/
if
(
process
.
env
.
NODE_ENV
!==
'build'
)
{
var
WebSocket
=
require
(
'ws'
);
// jshint ignore:line
var
web3
=
require
(
'./
web3
'
);
// jshint ignore:line
var
web3
=
require
(
'./
main.js
'
);
// jshint ignore:line
}
var
AutoProvider
=
function
(
userOptions
)
{
...
...
@@ -44,13 +44,13 @@ var AutoProvider = function (userOptions) {
this
.
provider
=
new
web3
.
providers
.
QtProvider
();
return
;
}
userOptions
=
userOptions
||
{};
var
options
=
{
httprpc
:
userOptions
.
httprpc
||
'http://localhost:8080'
,
websockets
:
userOptions
.
websockets
||
'ws://localhost:40404/eth'
};
var
self
=
this
;
var
closeWithSuccess
=
function
(
success
)
{
ws
.
close
();
...
...
@@ -71,7 +71,7 @@ var AutoProvider = function (userOptions) {
var
ws
=
new
WebSocket
(
options
.
websockets
);
ws
.
onopen
=
function
()
{
closeWithSuccess
(
true
);
closeWithSuccess
(
true
);
};
ws
.
onerror
=
function
()
{
...
...
package.json
View file @
04845d42
{
"name"
:
"ethereum.js"
,
"namespace"
:
"ethereum"
,
"version"
:
"0.0.
3
"
,
"version"
:
"0.0.
5
"
,
"description"
:
"Ethereum Compatible JavaScript API"
,
"main"
:
"./index.js"
,
"directories"
:
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment