Revision 025046f1 trunk/Pithos.Core/Agents/StatusAgent.cs
b/trunk/Pithos.Core/Agents/StatusAgent.cs | ||
---|---|---|
43 | 43 |
ActiveRecordStarter.CreateSchema(); |
44 | 44 |
|
45 | 45 |
CreateTrigger(); |
46 |
|
|
46 | 47 |
} |
47 | 48 |
|
48 | 49 |
private void CreateTrigger() |
... | ... | |
614 | 615 |
var command = new SQLiteCommand("select FileStatus from FileState where FilePath=:path COLLATE NOCASE", connection); |
615 | 616 |
command.Parameters.AddWithValue("path", path); |
616 | 617 |
|
617 |
var s = command.ExecuteScalar(); |
|
618 |
return (FileStatus)Convert.ToInt32(s); |
|
618 |
var statusValue = command.ExecuteScalar(); |
|
619 |
if (statusValue==null) |
|
620 |
return FileStatus.Missing; |
|
621 |
return (FileStatus)Convert.ToInt32(statusValue); |
|
619 | 622 |
} |
620 | 623 |
} |
621 | 624 |
|
Also available in: Unified diff