move newObjectIds into if stmnt

This commit is contained in:
Andy Gup 2015-07-28 16:49:05 -06:00
parent 655a76d92b
commit db99873ee1

View File

@ -1921,12 +1921,13 @@ define([
function (addResults, updateResults, deleteResults) {
layer._phantomLayer.clear();
var newObjectIds = addResults.map(function (r) {
return r.objectId;
});
// We use a different pattern if the attachmentsStore is valid and the layer has attachments
if (layer._attachmentsStore != null && layer.hasAttachments && tempObjectIds.length > 0) {
var newObjectIds = addResults.map(function (r) {
return r.objectId;
});
layer._replaceFeatureIds(tempObjectIds, newObjectIds, function (success) {
dfd.resolve({
id: id,