websockets implemented
This commit is contained in:
18
backend/controllers/falukantController.js
Normal file
18
backend/controllers/falukantController.js
Normal file
@@ -0,0 +1,18 @@
|
||||
import * as falukantService from '../services/falukantService.js';
|
||||
|
||||
class FalukantController {
|
||||
constructor() {
|
||||
this.exampleMethod = this.exampleMethod.bind(this);
|
||||
}
|
||||
|
||||
async exampleMethod(req, res) {
|
||||
try {
|
||||
const result = await falukantService.exampleMethod();
|
||||
res.status(200).json(result);
|
||||
} catch (error) {
|
||||
res.status(500).json({ error: error.message });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
export default FalukantController;
|
||||
Reference in New Issue
Block a user