| 7 | namespace { |
| 8 | |
| 9 | static Value Test(const CallbackInfo& info) { |
| 10 | Object resource = info[0].As<Object>(); |
| 11 | Function cb = info[1].As<Function>(); |
| 12 | ThreadSafeFunction tsfn = |
| 13 | ThreadSafeFunction::New(info.Env(), cb, resource, "Test", 1, 1); |
| 14 | tsfn.Release(); |
| 15 | return info.Env().Undefined(); |
| 16 | } |
| 17 | |
| 18 | } // namespace |
| 19 |