File tree 2 files changed +4
-4
lines changed
2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -157,7 +157,7 @@ namespace bee::lua_channel {
157
157
auto name = lua::checkstrview (L, 1 );
158
158
channel::box c = g_channel.query (name);
159
159
if (!c) {
160
- return luaL_error (L, " Can't query channel '%s' " , name. data ()) ;
160
+ return 0 ;
161
161
}
162
162
lua::newudata<channel::box>(L, c);
163
163
return 1 ;
Original file line number Diff line number Diff line change 11
11
local test_channel = lt .test " channel"
12
12
13
13
function test_channel :test_create ()
14
- lt .assertErrorMsgEquals ( " Can't query channel 'test' " , channel .query , " test" )
14
+ lt .assertIsNil ( channel .query " test" )
15
15
channel .create " test"
16
16
lt .assertIsUserdata (channel .query " test" )
17
17
lt .assertIsUserdata (channel .query " test" )
@@ -22,11 +22,11 @@ function test_channel:test_create()
22
22
end
23
23
24
24
function test_channel :test_reset_1 ()
25
- lt .assertErrorMsgEquals ( " Can't query channel 'test' " , channel .query , " test" )
25
+ lt .assertIsNil ( channel .query " test" )
26
26
channel .create " test"
27
27
lt .assertIsUserdata (channel .query " test" )
28
28
channel .destroy " test"
29
- lt .assertErrorMsgEquals ( " Can't query channel 'test' " , channel .query , " test" )
29
+ lt .assertIsNil ( channel .query " test" )
30
30
channel .create " test"
31
31
lt .assertIsUserdata (channel .query " test" )
32
32
channel .destroy " test"
You can’t perform that action at this time.
0 commit comments