diff --git a/scheduler.module b/scheduler.module
index ff520ca..542f017 100644
--- a/scheduler.module
+++ b/scheduler.module
@@ -699,6 +699,10 @@ function _scheduler_publish() {
 
   foreach ($nids as $nid) {
     $n = node_load($nid);
+    // Prevent creating empty nodes.
+    if (!_scheduler_check_node($n, $nid)) {
+      continue;
+    }
     $n->changed = $n->publish_on;
     $old_creation_date = $n->created;
     if (variable_get('scheduler_publish_touch_'. $n->type, 0) == 1) {
@@ -759,6 +763,10 @@ function _scheduler_unpublish() {
     // If this node is to be unpublished, we can update the node and remove the
     // record since it cannot be republished.
     $n = node_load($nid);
+    // Prevent creating empty nodes.
+    if (!_scheduler_check_node($n, $nid)) {
+      continue;
+    }
     $old_change_date = $n->changed;
     $n->changed = $n->unpublish_on;
 
@@ -788,6 +796,32 @@ function _scheduler_unpublish() {
 }
 
 /**
+ * Helper function to check for proper node_load()
+ *
+ * Prevent creating empty nodes if the node_load() for this nid fails for
+ * whatever reason. This is NOT a problem of the scheduler module but we do not
+ * want to increase the problems present by adding 'corrupted' nodes to the
+ * already corrupted database.
+ *
+ * @param $node
+ *  The fully loaded node object.
+ * @param $nid
+ *  The node id used to load the node.
+ *
+ * @return
+ *   boolean indicating succesfull load or not.
+ */
+function _scheduler_check_node($node, $nid) {
+  if (!is_object($node) || !isset($node->type) || empty($node->type)) {
+    watchdog('scheduler', 'Failed loading node with nid @nid!. This can have various root causes, e.g. does the uid that created this node still exist?', array('@nid' => $nid), WATCHDOG_ERROR, l(t('view'), 'node/'. $nid));
+    return FALSE;
+  }
+
+  return TRUE;
+}
+
+
+/**
  * Gather node IDs for all nodes that need to be $action'ed
  *
  * @param $action
