mirror of
https://github.com/RustyRaptor/brackets.git
synced 2026-12-04 00:15:22 -07:00
Change for-in loop to Collections.forEach to satify JSLint (looks like a bug in JSLint though)
This commit is contained in:
1 parent
dbb7d3f4d3
commit
33a016da6d
1 file changed
+6
-7
@@ -308,20 +308,19 @@ define(function (require, exports, module) {
|
||||
*/
|
||||
function getPendingRequest(file, offset, type) {
|
||||
var key = file + "@" + offset;
|
||||
if (Object.prototype.hasOwnProperty.call(pendingTernRequests, key)) {
|
||||
if (CollectionUtils.hasProperty(pendingTernRequests, key)) {
|
||||
var requests = pendingTernRequests[key],
|
||||
requestType = requests[type],
|
||||
anyProperties = false;
|
||||
|
||||
delete pendingTernRequests[key][type];
|
||||
|
||||
for (var prop in requests) {
|
||||
if (CollectionUtils.hasProperty(requests, prop)) {
|
||||
|
||||
CollectionUtils.forEach(requests, function (requestValue, requestKey) {
|
||||
if (CollectionUtils.hasProperty(requests, requestKey)) {
|
||||
anyProperties = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
if (!anyProperties) {
|
||||
delete pendingTernRequests[key];
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user