Skip to content

Commit

Permalink
Update quickreply.js
Browse files Browse the repository at this point in the history
  • Loading branch information
RongYYYY authored Oct 24, 2024
1 parent d900023 commit 89fdd49
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions public/src/modules/quickreply.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@ define('quickreply', [
}

const replyMsg = components.get('topic/quickreply/text').val();
const replyAt = $('#replyAt').val(); // Capture the scheduled date and time
const replyAt = $('#replyAt').val();
const isAnon = components.get('topic/quickreply/anonymousCheckbox').is(':checked');
const replyData = {
tid: ajaxify.data.tid,
handle: isAnon ? 'anonymous' : undefined,
content: replyMsg,
scheduledDate: replyAt || null // Add the scheduled date to the request if it exists
scheduledDate: replyAt || null

Check failure on line 67 in public/src/modules/quickreply.js

View workflow job for this annotation

GitHub Actions / lint-and-test / test

Missing trailing comma
};
const replyLen = replyMsg.length;
if (replyLen < parseInt(config.minimumPostLength, 10)) {
Expand All @@ -73,7 +73,7 @@ define('quickreply', [
return alerts.error('[[error:content-too-long, ' + config.maximumPostLength + ']]');
}

console.log("Sending reply data to backend:", replyData);
console.log('Sending reply data to backend:', replyData);


ready = false;
Expand All @@ -82,7 +82,7 @@ define('quickreply', [
if (err) {
return alerts.error(err);
}
console.log("Response from backend:", data);
console.log('Response from backend:', data);

if (data && data.queued) {
alerts.alert({
Expand Down

0 comments on commit 89fdd49

Please sign in to comment.