Skip to content

Commit

Permalink
move WebAudio keyboard RT seconds-to-ms conversion from audio-keyboar…
Browse files Browse the repository at this point in the history
…d-response plugin to getKeyboardResponse
  • Loading branch information
becky-gilbert committed Apr 9, 2021
1 parent 94a094f commit fb2ad41
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
2 changes: 1 addition & 1 deletion jspsych.js
Original file line number Diff line number Diff line change
Expand Up @@ -2337,7 +2337,7 @@ jsPsych.pluginAPI = (function() {
}
parameters.callback_function({
key: key,
rt: rt,
rt: rt_ms,
});

if (keyboard_listeners.includes(listener_id)) {
Expand Down
3 changes: 0 additions & 3 deletions plugins/jspsych-audio-keyboard-response.js
Original file line number Diff line number Diff line change
Expand Up @@ -155,9 +155,6 @@ jsPsych.plugins["audio-keyboard-response"] = (function () {
jsPsych.pluginAPI.cancelAllKeyboardResponses();

// gather the data to store for the trial
if (context !== null && response.rt !== null) {
response.rt = Math.round(response.rt * 1000);
}
var trial_data = {
rt: response.rt,
stimulus: trial.stimulus,
Expand Down

0 comments on commit fb2ad41

Please sign in to comment.