Skip to content

Commit

Permalink
Removing commented out code
Browse files Browse the repository at this point in the history
  • Loading branch information
lewisl9029 committed Sep 4, 2015
1 parent 2e0d029 commit aa88ac6
Showing 1 changed file with 0 additions and 45 deletions.
45 changes: 0 additions & 45 deletions app/views/channel/channel-controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,49 +40,4 @@ export default /*@ngInject*/ function ChannelController(

return messages.saveSendingMessage(this.channelId, message);
};

//TODO: add to offline message queue instead of blocking further input
// this.send = () => {
// const MAX_ATTEMPTS = 3;
// let attemptCount = 0;
// let recursivelySendMessage = () => {
// let logicalClock = channelCursor.get(['logicalClock']);
//
// return network.sendMessage(
// channelCursor.get(['channelInfo']),
// this.message,
// logicalClock + 1
// )
// .then(() => {
// let currentLogicalClock = channelCursor
// .get(['logicalClock']);
//
// return state.save(
// channelCursor,
// ['logicalClock'],
// currentLogicalClock + 1
// );
// })
// .catch((error) => {
// if (error !== 'timeout') {
// return $q.reject(error);
// }
//
// attemptCount++;
// if (attemptCount === MAX_ATTEMPTS) {
// return $q.reject('Message sending has timed out.');
// }
//
// return recursivelySendMessage();
// });
// };
//
// this.sending = recursivelySendMessage()
// .then(() => {
// this.message = '';
// return $q.when();
// });
//
// return this.sending;
// };
}

0 comments on commit aa88ac6

Please sign in to comment.