t is not a constructor

Upon trying to add data to my application’s database I recieve an error “backendless.min.js?_=1471359669124:formatted:772Uncaught TypeError: t is not a constructor”

I have created a basic test html file using the exact same javascript and the error does not persist.

Application id is: 04346FCB-DC42-0F46-FF7C-7DC578787800
I have included screenshots of the error statement as well as the code that produces it and the test code which does not.

I would also like to add that I am in the midst of transitioning from parse (hence the parse statements).

ErrorCode.PNG

Hi, Weston.

The tables names are case sensitive. The distinction in your code examples is just in size difference of first letter. Try to change the method name to match the name of the table.

Thank you, the reason the table name is lowercase is because that table was imported from parse. However, when I use ‘Items’ as the method name in the application code, I receive the error shown in the screenshot. Oddly enough, ‘Item’ works perfectly.

Additionally, I can change the test code to ‘items’ and it works perfectly as well. I would prefer to use ‘items’ as it matches the data imported from Parse, but I would be up for anything that would work.

Thank you, the reason the table name is lowercase is because that table was imported from parse. However, when I use ‘Items’ as the method name in the application code, I receive the error shown in the screenshot. Oddly enough, ‘Item’ works perfectly.

Additionally, I can change the test code to ‘items’ and it works perfectly as well. I would prefer to use ‘items’ as it matches the data imported from Parse, but I would be up for anything that would work.

Hi Weston,

Here is example that demonstrates how to save data to your table:

https://jsfiddle.net/e8psfeqc/

Don’t forget to set your app settings to initApp method.

Regards,

Denys

See below

Thank you for your response, I seem to have been able to fix it by putting the items function within the newItem function in my code. What baffles me is that in the simple test file I made this was not necessary. The code ran perfectly with the functions separated out.