Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
N
Neos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
love_飞影
Neos
Commits
270df721
Commit
270df721
authored
Aug 20, 2023
by
Chunchi Che
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'optimize/koishi' into 'main'
update koishi ip See merge request
!279
parents
6367b81e
2de1ce8e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
1 deletion
+8
-1
neos.config.prod.json
neos.config.prod.json
+1
-1
src/infra/stream.ts
src/infra/stream.ts
+7
-0
No files found.
neos.config.prod.json
View file @
270df721
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
"servers"
:[
"servers"
:[
{
{
"name"
:
"koishi"
,
"name"
:
"koishi"
,
"ip"
:
"koishi
-r
.momobako.com"
,
"ip"
:
"koishi.momobako.com"
,
"port"
:
"7211"
"port"
:
"7211"
}
}
],
],
...
...
src/infra/stream.ts
View file @
270df721
...
@@ -17,6 +17,13 @@ export class WebSocketStream {
...
@@ -17,6 +17,13 @@ export class WebSocketStream {
if
(
onWsOpen
)
{
if
(
onWsOpen
)
{
this
.
ws
.
onopen
=
(
e
)
=>
onWsOpen
(
this
.
ws
,
e
);
this
.
ws
.
onopen
=
(
e
)
=>
onWsOpen
(
this
.
ws
,
e
);
}
}
this
.
ws
.
onerror
=
(
e
)
=>
{
if
(
e
instanceof
ErrorEvent
)
{
alert
(
`websocket error:
${
e
.
message
}
`
);
}
else
{
alert
(
`websocket connect to
${
ip
}
error`
);
}
};
const
ws
=
this
.
ws
;
const
ws
=
this
.
ws
;
this
.
stream
=
new
ReadableStream
({
this
.
stream
=
new
ReadableStream
({
...
...
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