Skip to content

Commit

Permalink
Include optional arguments for legacy support
Browse files Browse the repository at this point in the history
  • Loading branch information
zalmoxisus committed Jan 11, 2017
1 parent 023b558 commit 2b249b3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/app/api/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,13 +69,13 @@ export function toContentScript(message, serializeState, serializeAction) {
post(message);
}

export function sendMessage(action, state, config) {
export function sendMessage(action, state, config, instanceId, name) {
if (typeof config !== 'object') config = {}; // eslint-disable-line no-param-reassign
const message = {
payload: state,
source,
name: config.name,
instanceId: config.instanceId || 1
name: config.name || name,
instanceId: config.instanceId || instanceId || 1
};
if (action) {
message.type = 'ACTION';
Expand Down

0 comments on commit 2b249b3

Please sign in to comment.