Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on May 25, 2019. It is now read-only.

Commit 0a65097

Browse files
Removing more debug lines
Changing order of execution
1 parent acb865e commit 0a65097

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

‎main.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -165,26 +165,23 @@ define(function (require, exports, module) {
165165
function provider(hostEditor, pos) {
166166
// Only provide an editor when cursor is in HTML content
167167
if (hostEditor.getModeForSelection() !== "html") {
168-
console.info('AJS: No HTML');
169168
return null;
170169
}
171170

172171
// Only provide an editor if the selection is within a single line
173172
var sel = hostEditor.getSelection();
174173
if (sel.start.line !== sel.end.line) {
175-
console.info('AJS: Multi Selection');
176174
return null;
177175
}
178176

179177
// Always use the selection start for determining the function name. The pos
180178
// parameter is usually the selection end.
181-
var directiveName = _getDirectiveName(hostEditor, sel.start),
182-
controllerName = _getControllerName(hostEditor, sel.start);
183-
179+
var controllerName = _getControllerName(hostEditor, sel.start);
184180
if (controllerName) {
185181
return _createInlineEditor(hostEditor, controllerName, patterns.controller);
186182
}
187183

184+
var directiveName = _getDirectiveName(hostEditor, sel.start);
188185
if (directiveName) {
189186
return _createInlineEditor(hostEditor, directiveName, patterns.directive);
190187
}

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /