mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 09:48:58 -04:00
parent
ddc5b554a6
commit
8fa2c7bafe
2 changed files with 7 additions and 1 deletions
|
@ -181,7 +181,7 @@ function getCurrentMethodAndTokenPaths(editor, pos, forceEndOfUrl) {
|
|||
}
|
||||
ret.urlTokenPath = [];
|
||||
if (tokenIter.getCurrentTokenRow() === startPos.row) {
|
||||
if (t.type === 'url.part' || t.type === 'url.param' || t.type === 'url.value') {
|
||||
if (t && (t.type === 'url.part' || t.type === 'url.param' || t.type === 'url.value')) {
|
||||
// we are forcing the end of the url for the purposes of determining an endpoint
|
||||
if (forceEndOfUrl && t.type === 'url.part') {
|
||||
ret.urlTokenPath.push(t.value);
|
||||
|
|
|
@ -291,6 +291,9 @@ export default function SenseEditor($el) {
|
|||
|
||||
|
||||
editor.getRequestInRange = onceDoneTokenizing(function (range, cb) {
|
||||
if (!range) {
|
||||
return;
|
||||
}
|
||||
const request = {
|
||||
method: '',
|
||||
data: [],
|
||||
|
@ -379,6 +382,9 @@ export default function SenseEditor($el) {
|
|||
}
|
||||
|
||||
editor.getRequest(currentRow, function (request) {
|
||||
if (!request) {
|
||||
return;
|
||||
}
|
||||
explicitRangeToRequests({
|
||||
start: {
|
||||
row: request.range.end.row + 1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue