mirror of
https://github.com/onyx-and-iris/meld-cli.git
synced 2025-07-12 02:11:46 +00:00
lint fixes
This commit is contained in:
parent
4f401a750a
commit
008989dc83
1
index.js
1
index.js
@ -34,6 +34,7 @@ function printHelp(helpText) {
|
||||
* @param {function} fn - The function to execute with the channel.
|
||||
*/
|
||||
function withChannel (socket, fn) {
|
||||
// eslint-disable-next-line no-new
|
||||
new QWebChannel(socket, function (channel) {
|
||||
fn(channel)
|
||||
.then((result) => {
|
||||
|
@ -19,12 +19,8 @@ const clipHelp = meowHelp({
|
||||
})
|
||||
|
||||
async function saveClip (channel) {
|
||||
try {
|
||||
await channel.objects.meld.sendCommand('meld.recordClip');
|
||||
return 'Clip command sent successfully.';
|
||||
} catch (err) {
|
||||
throw err;
|
||||
}
|
||||
await channel.objects.meld.sendCommand('meld.recordClip')
|
||||
return 'Clip command sent successfully.'
|
||||
}
|
||||
|
||||
export { clipHelp, saveClip }
|
||||
|
@ -19,12 +19,8 @@ const screenshotHelp = meowHelp({
|
||||
})
|
||||
|
||||
async function takeScreenshot (channel) {
|
||||
try {
|
||||
await channel.objects.meld.sendCommand('meld.screenshot');
|
||||
return 'Screenshot command sent successfully.';
|
||||
} catch (err) {
|
||||
throw err;
|
||||
}
|
||||
await channel.objects.meld.sendCommand('meld.screenshot')
|
||||
return 'Screenshot command sent successfully.'
|
||||
}
|
||||
|
||||
export { screenshotHelp, takeScreenshot }
|
Loading…
x
Reference in New Issue
Block a user