Remove name from insert method - this is removed from db schema
This commit is contained in:
@@ -17,9 +17,9 @@ class SiteModel {
|
||||
*
|
||||
* @returns {Promise<Object>} - The result of the insert operation.
|
||||
*/
|
||||
async insert(name, domainName) {
|
||||
async insert(domainName) {
|
||||
// validate inputs
|
||||
if (!name || !domainName) {
|
||||
if (!domainName) {
|
||||
throw new Error('Name and domain name are required to insert a site.');
|
||||
}
|
||||
|
||||
@@ -34,7 +34,6 @@ class SiteModel {
|
||||
}
|
||||
|
||||
const { data, error } = await supabase.from(SiteModel.tableName).insert({
|
||||
name: name,
|
||||
domain_name: domainName,
|
||||
}).select();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user