Skip to content

Commit

Permalink
Fix Error message, Closes #144
Browse files Browse the repository at this point in the history
  • Loading branch information
Nexela committed Sep 28, 2019
1 parent 1dc685c commit 681ad9b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion stdlib/event/event.lua
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ if not config.skip_script_protections then -- Protections for post and pre regis
end
for name in pairs(Event.script) do
_G.script[name] = function(id)
error('Detected attempt to register an event using script.' .. name .. ' while using the STDLIB event system ' .. id and id or '')
error('Detected attempt to register an event using script.' .. name .. ' while using the STDLIB event system ' .. (id and id or ''))
end
end
end
Expand Down
2 changes: 1 addition & 1 deletion stdlib/event/trains.lua
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ local table = require('__stdlib__/stdlib/utils/table')
-- @tparam uint new_id the ID of the train after the change
-- @usage
---- Event.register(Trains.on_train_id_changed, my_handler)
Trains.on_train_id_changed = script.generate_event_name()
Trains.on_train_id_changed = Event.generate_event_name()

--- Given a @{criteria|search criteria}, search for trains that match the criteria.
-- * If ***criteria.surface*** is not supplied, this function searches through all existing surfaces.
Expand Down

0 comments on commit 681ad9b

Please sign in to comment.