Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions src/components/PrimaryNavigation.vue
Original file line number Diff line number Diff line change
Expand Up @@ -60,15 +60,16 @@
</nav>

<nav id="cve-secondary-navbar" class="navbar" aria-label="navigation">
<div class="navbar-menu cve-secondary-navbar-menu is-active">
<div class="navbar-start" style="flex-grow: 1 !important; justify-content: center !important;">
<div class="navbar-menu cve-secondary-navbar-menu is-active" style="display: block">
<div class="navbar-start" style="flex-grow: 1 !important; align-items: center !important; justify-content: center !important;
flex-direction: column !important">
<div class="navbar-item cve-secondary-navbar-item">
<cveRecordLookup/>
</div>
<div class="navbar-item cve-secondary-navbar-item cve-keyword-search">
<span class="icon-text">
<span class="icon-text" style="font-size: 14px">
<a href="https://cve.mitre.org/cve/search_cve_list.html" target="_blank" class="cve-dark-blue-text">
Need a CVE ID? Find one here by keyword
Need a CVE Record? Find one by keyword on cve.mitre.org
<span class="icon cve-icon-xxs" style="margin-left: 0px;">
<p id="CVERecordsKeywordSearch" class="is-hidden">external site</p>
<font-awesome-icon icon="external-link-alt" aria-labelledby="CVERecordsKeywordSearch">
Expand Down
7 changes: 4 additions & 3 deletions src/components/cveRecordLookupModule.vue
Original file line number Diff line number Diff line change
Expand Up @@ -143,15 +143,16 @@ export default ({
axios
.get(url, { timeout: 30000 })
.then((res) => {
const response = res;
this.$store.commit('updateState', { showHelpText: false });
this.$store.commit('updateState', { isSearching: false });

if (res.status === 200) {
if (Object.prototype.hasOwnProperty.call(res.data, 'error')) {
if (response.status === 200 && typeof response.data === 'object') {
if (Object.prototype.hasOwnProperty.call(response.data, 'error')) {
self.$store.commit('updateState', { error: true });
}

this.handleCveRecordDisplay(res.data);
this.handleCveRecordDisplay(response.data);
} else {
this.handleServerError();
}
Expand Down