Work on adding files to a Journal Entry
This commit is contained in:
@@ -86,7 +86,7 @@ export async function load_ae_obj_li__hosted_file(
|
||||
}
|
||||
|
||||
// Check if for_obj_type is in the list of valid Aether object types:
|
||||
let valid_for_obj_types = ['account', 'archive', 'archive_content', 'event', 'event_session', 'event_presentation', 'event_presenter', 'event_location', 'post', 'post_comment'];
|
||||
let valid_for_obj_types = ['account', 'archive', 'archive_content', 'event', 'event_session', 'event_presentation', 'event_presenter', 'event_location', 'journal', 'journal_entry', 'post', 'post_comment'];
|
||||
if (!valid_for_obj_types.includes(for_obj_type)) {
|
||||
console.log(`Invalid for_obj_type: ${for_obj_type}`);
|
||||
return [];
|
||||
|
||||
@@ -18,7 +18,7 @@ export async function db_save_ae_obj_li__ae_obj({
|
||||
properties_to_save: string[];
|
||||
log_lvl?: number;
|
||||
}) {
|
||||
log_lvl = 1;
|
||||
// log_lvl = 1;
|
||||
if (log_lvl) {
|
||||
console.log(`*** db_save_ae_obj_li__ae_obj() *** table_name=${table_name}`, obj_li);
|
||||
}
|
||||
@@ -72,7 +72,7 @@ export async function db_save_ae_obj_li__ae_obj({
|
||||
} catch (error) {
|
||||
// This is fairly common and normal if the object is new
|
||||
if (log_lvl) {
|
||||
console.error(`Bulk update failed. Falling back to bulkPut.`, error);
|
||||
console.log(`Bulk update failed. Falling back to bulkPut. This is normal.`, error);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -85,7 +85,7 @@ export async function db_save_ae_obj_li__ae_obj({
|
||||
return putKeys;
|
||||
} catch (error) {
|
||||
// This should not happen if the object is new
|
||||
console.error(`Bulk put failed.`, error);
|
||||
console.error(`Bulk put failed. Something likely went wrong!`, error);
|
||||
return [];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user