ready4testing
This commit is contained in:
@@ -21,3 +21,16 @@ exports.index = function(req, res, next) {
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
exports.play = function(req, res, next) {
|
||||
var id = req.params.id;
|
||||
|
||||
Log.trace('Router: ID ' + id + ' wanted');
|
||||
|
||||
if(Helper.isDefinedAndNotNull(Radio.getChannel(id))) {
|
||||
Radio.play(id);
|
||||
res.sendStatus(200);
|
||||
} else {
|
||||
res.sendStatus(400);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user