Skip to content

Commit 6df2cac

Browse files
committedApr 4, 2016
Some changes related to #184.
1 parent 92734a1 commit 6df2cac

File tree

1 file changed

+3
-3
lines changed
  • src/main/resources/assets/computronics/lua/component/tape_drive/bin

1 file changed

+3
-3
lines changed
 

‎src/main/resources/assets/computronics/lua/component/tape_drive/bin/tape.lua

+3-3
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ local function writeTape(path)
179179
end
180180

181181
local connected, reason = false, ""
182-
for i = 1, 50, 1 do
182+
for i = 1, 50 do
183183
connected, reason = file.finishConnect()
184184
os.sleep(.1)
185185
if connected or connected == nil then
@@ -195,9 +195,9 @@ local function writeTape(path)
195195
local status, message, header = file.response()
196196

197197
if status then
198-
status = math.tointeger and math.tointeger(status) or status
198+
status = string.format("%d", status)
199199
print("Status: " .. status .. " " .. message)
200-
if string.format("%d", status):sub(1,1) == "2" then
200+
if status:sub(1,1) == "2" then
201201
return true, {
202202
close = function(self, ...) return file.close(...) end,
203203
read = function(self, ...) return file.read(...) end,

0 commit comments

Comments
 (0)
Please sign in to comment.