Skip to content

Commit

Permalink
Fix typo in cut/copy handlers
Browse files Browse the repository at this point in the history
  • Loading branch information
neilj committed Mar 14, 2016
1 parent 41d7346 commit 349f391
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions source/Clipboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ var onCut = function ( event ) {
moveRangeBoundariesUpTree( range, body );
node.appendChild( deleteContentsOfRange( range, body ) );
clipboardData.setData( 'text/html', node.innerHTML );
clipboard.setData( 'text/plain', node.innerText || node.textContent );
clipboardData.setData( 'text/plain',
node.innerText || node.textContent );
event.preventDefault();
} else {
setTimeout( function () {
Expand All @@ -40,7 +41,8 @@ var onCopy = function ( event ) {
if ( !isEdge && clipboardData ) {
node.appendChild( range.cloneContents() );
clipboardData.setData( 'text/html', node.innerHTML );
clipboard.setData( 'text/plain', node.innerText || node.textContent );
clipboardData.setData( 'text/plain',
node.innerText || node.textContent );
event.preventDefault();
}
};
Expand Down

0 comments on commit 349f391

Please sign in to comment.