As you can see below, I have a variable called "olddata". It uses GetAsync on a key dependent on player userids. According to the Wiki, if the key doesn't exist, it should return nil. I tested this out on a brand-new account, and alas, it didn't return nil. Does anybody have a solution to this?
local olddata = game:GetService("DataStoreService"):GetDataStore("Pokemon"):GetAsync("user_"..newPlayer.userId.."_Pokemon")
if (olddata ~= nil and olddata ~= "1") then
--stuff
end

3 comments
What did it return ?
ummmm you forgot a closing parenthsis near :GetAsync("user" .. ) and another value to follow after ..
@koolkid You have to read the SourceCode for it. Also, I found the issue. It was in a different one of my scripts. Thanks for the help anyways!