Skip to content

Commit

Permalink
handle "$options === null" case
Browse files Browse the repository at this point in the history
  • Loading branch information
moxun1639 committed Jun 29, 2023
1 parent 50250a2 commit 02dab60
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions dist/vue-data-dict.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vue-data-dict",
"version": "1.2.0",
"version": "1.2.1",
"description": "data dict for Vue.js",
"main": "src/index.js",
"unpkg": "dist/vue-data-dict.js",
Expand Down
6 changes: 3 additions & 3 deletions src/lib/install.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import Dependency from './Dependency'
import Dependency from './Dependency'
import Dict from './Dict'
import { mergeOptions } from './DictOptions'

export default function(Vue, options) {
Dependency.Vue = Vue
Dependency.Vue = Vue
mergeOptions(options)
Vue.mixin({
data() {
if (this.$options.dicts === undefined || this.$options.dicts === null) {
if (!this.$options || this.$options.dicts === undefined || this.$options.dicts === null) {
return {}
}
const dict = new Dict()
Expand Down

0 comments on commit 02dab60

Please sign in to comment.